0

I set up a test domain to try CiviMobile. I got it to work but it only shows the test event I set up. Drupal 9.1.9 / CiviCRM 5.37.2 / CiviMobileAPI 5.6.1 / PHP 7.4.14 / Android 8.0.0

I have administrative rights. When I logout of CiviMobile it presents the login screen. When I login it spins a bit then stays on the login screen, showing my username and password and above it, it says You are connected to https://xxx.dreamhosters.com. If I mess up the password it gives me an error message. I touch "Back" on the login screen and it says 'There are no events'. If I touch <-- Back at the top of the screen, I get the 'Change server' message. If I say OK, it shows the Civi URL and a Connect button. Touch that and it shows the test event I set up, but there's no other menu items along the bottom of the screen. I can't see any of the contacts in the database. I installed the CiviCalendar Extension too, but it doesn't show up. The CiviMobile Checklist looks good, except it says the Rest url and the Rest Path are not correct. What's that? Please advise...thanks!

UPDATE: I found rest.php, but it was in .../ffv.dreamhosters.com/vendor/civicrm/civicrm-core/extern. Then I realized Civi Directories & Resource URLs had different [civicrm.root] directories, so I posted Resource URLs Screen has the wrong [civicrm.root] Then I moved my Extensions directory to the preferred location: .../sites/default/files/civicrm/ Reinstalled CiviMobile, Updated Paths, emptied the Civi cache and my browser cache. But it's still complaining that the Rest Path is wrong, so I copied the Extern directory to where CiviMobile wants it to be .../libraries/civicrm/core/ but it's still not happy...Please Help!

2
  • Hi did you figure this out? I'm having the same problem with a fresh install of Drupal 9. Feb 1, 2022 at 11:13
  • We're not using CiviMobile at this time. If you read the comments below, you'll see I got it to work with WordPress which was our preferred CMS anyway.
    – jimcrist
    Feb 1, 2022 at 15:59

2 Answers 2

1

I'm having the same problem with a fresh install of Drupal 9.

I've managed to get rid of the "REST url path incorrect" message at /civicrm/civimobile/checklist in a very hacky way, but still when I use the app on my phone the only thing that is visible is Events.

Here is how I got REST working:

  1. Added "RewriteCond %{REQUEST_URI} !/libraries/civicrm/core/extern/rest.php$" to .htaccess in web root (note this gets overwritten when you use "composer require").

  2. created web/libraries/civicrm/core/civicrm.config.php file by copying it from an older installation, as this file is missing in a fresh D9 + Civi install.

  3. copied the directory vendor/civicrm/civicrm-core/extern to web/libraries/civicrm/core.

  4. Edited civicrm.config.php and added the following at line 86: $confdir = '../../../sites/default';

1
0

Please make sure permission settings are correct:
https://civimobile.org/permissions/

In order to view the calendar, they should be
CiviCRM: access CiviCRM backend and API
CiviCRM: view my contact
CiviEvent: access CiviEvent
CiviEvent: view event info

View contacts:
CiviCRM: access CiviCRM backend and API
CiviCRM: view my contact
CiviCRM: view all contacts


Please also check the calendar settings in Administration/CiviMobile/CiviMobile Calendar Settings:

enter image description here

Did you check "Synchronize with CiviCalendar"?

enter image description here


Did you clear the cache afterwards?

6
  • Thanks for the prompt reply! The calendar was synched. I just cleared the cache on my browser and reconnected with CiviMobile, but no change. I'm the administrator that recently set up this test domain. The Drupal, Civi everything. I can see and edit my contacts and Events in CiviCRM. When I look at the Drupal > People > Permissions they all have a greyed out check mark under Administrator, except a few of the more basic permissions where Anonymous and Authenticated users are checked. I can't find rest.php anywhere (see the end of my original question). Is that a problem?
    – jimcrist
    Jun 7, 2021 at 17:36
  • Yes, it is! Did you upgrade from an older drupal version? Have a look at drupal.org/project/drupal/issues/3153769#comment-13948137 I don't run CiviCRM/CiviMobile on Drupal, therefore I'm not sure, if this corresponds to the wrong feature behaviour in your case...
    – Guitarman
    Jun 7, 2021 at 19:25
  • It's a fresh install of everything. I didn't upgrade Drupal. Thanks for the link, but it doesn't say how to find the file that needs editing.
    – jimcrist
    Jun 7, 2021 at 20:28
  • rest.php should be in /drupal/sites/all/modules/civicrm/extern/rest.php Probably the path to the civicrm.settings.php file is not correct and as consequence the APIv3 Rest query doesn't work?!
    – Guitarman
    Jun 7, 2021 at 21:08
  • I'm still stuck and frustrated. Please see Update to my original post. Thanks in advance...
    – jimcrist
    Jun 8, 2021 at 19:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.