Login widget fails to login, even with known good credentials.
- Disable Plugins - The Service Portal plugin utilizes WordPress's user management capabilities to provide your customers with the ability to log into your website. You should disable any plugins that prevent users from logging into WordPress.
- Disable ReCaptcha - ReCaptcha is not supported by the Service Portal login widget. Disable the ReCaptcha check in the login to allow the Service Portal to authenticate users.
- If you do not wish to disable ReCaptcha, you will not be able to use the Service Portal login widget that we provide. You may wish to consider using a standard WP login page (which will work). Be sure to redirect users to the Service Portal content page that you created using the Service Portal installation guide. Note that self-service requesting a Service Portal account is a function of the login widget. If you do not use the login widget, you will need to manually create accounts for your users, inside of the ServiceTrade settings within WP-admin.
'Failed to establish connection - please refresh your browser' error message
Check if your Service Portal Plugin User is Setup
If you receive the following error message check to make sure that you have a Service Portal Plugin user for the customer set up, and NOT a WordPress user for the customer set up.
Your API credentials may be incorrect.
To adjust your API credentials:
- Log into WordPress as an administrator.
- Click on ServiceTrade in the main menu.
- In the menu for ServiceTrade, click on Settings.
- Enter your ServiceTrade username and password in the appropriate boxes in the Configuration section of the settings page.
Your web server may be using an incompatible version of PHP or does not have the mcrypt extension.
To determine if WordPress is throwing PHP errors:
- Open the error_log file from your WordPress root directory. (This will most likely require File Manager access to your web host.)
- Look for lines that have something like "PHP Fatal error".
[13-Feb-2019 14:21:32 America/New_York] PHP Fatal error: Uncaught Error: Call to undefined function mcrypt_get_iv_size() in /home/p29zyd1ujfo8/public_html/portal/wp-content/plugins/servicetrade-service-portal/public/rest/class-authenticated-user.php:265
Your ServiceTrade user may not be granted the appropriate permissions.
To work properly, the ServiceTrade user whose credentials you enter into the portal settings page should be granted the "Account Admin" role. To adjust your user's permissions:
- Log into ServiceTrade as an administrator
- On the Navigation Bar click on My Account
- Then click Users
- Search for the user you are using for the portal plugin.
- Click on that user's name
- In the "Roles" section, ensure that "Account Admin" appears in the list of assigned roles.
- If necessary, choose "Account Admin" from the "Choose Role" dropdown, then click "Assign Role"
Your web server and/or Varnish cache may be deleting WordPress user session cookies.
To determine if WordPress session cookies are being dropped:
- Open your web site in the Google Chrome web browser.
- Click the Chrome menu, choose "More tools".
- Then choose "Developer tools"
- This will open the Chrome developer tools. In the developer tools window, click on the "Application" menu at the top.
- Then open "Cookies" under the "Storage" section:
- Under "Cookies", you will see one or more websites listed. Click on the name of your website.
- With the Chrome developer tools pane open, attempt to log into the Service Portal as a customer, using the email address and password of a portal user.
- View the list of cookies. You should see a cookie whose name begins with wordpress_, and another cookie whose name begins with wordpress_logged_in_, as shown below:
If these cookies do not appear, either your web server, Varnish, or another component of your website infrastructure is dropping WordPress user session cookies. Please contact your website developer to resolve this problem.