Support

Home Forums Event Espresso Premium EE4 Mobile App Error Message

EE4 Mobile App Error Message

Posted: March 2, 2020 at 4:08 pm

Viewing 12 reply threads


djgore

March 2, 2020 at 4:08 pm

Hello,

I’ve used the mobile app for a previous event, and it worked great. Now, I’ve tried to log in, and I’m getting the following error:

“The content data is in the wrong format.”

I found the troubleshooting document for this specific error message, and both of the action items are already done correctly on my website. The action items are copied below. How can I get the app working again?

1. The Mobile apps require that the permalinks are set to Post Name or similar scheme that uses %postname% (also known as Pretty Permalinks). The plain permalinks structure is not compatible with the API.

2. WP_DEBUG must be set to false. You can verify that WP_DEBUG is set to false by opening the wp-config.php file in a code editor.


Tony

  • Support Staff

March 3, 2020 at 5:56 am

Hi there,

Normally the above error means there are notices/warnings being thrown on the WP-JSON requests the app uses to communicate with your site, which is why we advise setting WP_DEBUG to false.

If you install the WP REST API Log plugin and try to log in again with the app, that plugin will log the request and response.

(Note you may need to enable logging in Settings -> REST API Log first)

View the logs in Tools -> REST API log and see if anything stands out there.


djgore

March 4, 2020 at 9:51 am

Hi Tony,

I installed WP REST API Log plugin and checked to make sure it was enabled. I then tried to log into the app on my Apple iOS device, and I’m getting a different error message showing that my password credentials is incorrect. It is strange because I am able to log in to eventespresso.com just fine on my browser, using the same login credentials.

I can see my login attempts on the WP REST API Log. What should I do?

Thanks


Josh

  • Support Staff

March 4, 2020 at 10:10 am

Hi,

When you use the apps you actually need to use the WP admin credentials for your website. Your website doesn’t use the credentials from eventespresso.com.


djgore

March 4, 2020 at 10:53 am

Thanks, Josh. Now that we have figured that out, I was able to log in. I am still seeing the error message “data is not in correct format”. I hit “OK”, and decided to click around on the bottom 4 icons (the A-Z, 1-9) and all of the events show up. When I click over to the most recent past event, I can view the first page, but clicking on “Attendees” causes that same error message to pop up.

Your help is greatly appreciated!


Josh

  • Support Staff

March 4, 2020 at 10:58 am

Did you view the logs in Tools -> REST API log to see if anything stands out there?


djgore

March 4, 2020 at 2:11 pm

Josh,

I do not see anything that necessarily stands out. May I show you screenshots or provide you a URL address to help? Here is a sample of what I’m seeing on the REST API Log: https://getbigorgohome.com/wp-content/uploads/2020/03/Screen-Shot-2020-03-04-at-4.09.41-PM.png


Josh

  • Support Staff

March 4, 2020 at 2:48 pm

If you click the title of any of those items in the log you’ll be able to see the details of the request. There may be an error message within those.


djgore

March 4, 2020 at 3:34 pm

Here is the specific log (except for Response Body) for a single time I got the error message (however I do not see an error message within- perhaps you can!). The log title is Route: /ee/v4.8.36/registrations

Request Headers:
{
“host”: “getbigorgohome.com”,
“x_real_ip”: “2601:cf:8100:93:35f8:a32b:8b8a:5370”,
“x_forwarded_proto”: “https”,
“accept_encoding”: “gzip”,
“connection”: “close”,
“cf_ipcountry”: “US”,
“cf_ray”: “56ef04652ebed310-ATL”,
“cf_visitor”: “{“scheme”:”https”}”,
“accept”: “*\/*”,
“user_agent”: “EventEspressoHD\/3.2.2 CFNetwork\/1121.2.2 Darwin\/19.3.0”,
“accept_language”: “en-us”,
“authorization”: “Basic ZGFybGE6VGVkZHkjMDgwNw==”,
“cookie”: “PHPSESSID=80dbc88e217e0c3d003aa1b1545765ee; __cfduid=d7c34d8becce90e07be92549bc418001c1583280764”,
“cf_connecting_ip”: “2601:cf:8100:93:35f8:a32b:8b8a:5370”,
“cdn_loop”: “cloudflare”,
“x_https”: “1”
}

Query Parameters:
{
“where”: {
“Event.EVT_ID”: “5316”,
“Ticket.Datetime.DTT_ID”: “33”,
“STS_ID”: [
“!=”,
“RIC”
]
},
“group_by”: [
“REG_ID”
],
“limit”: “0,20”,
“order_by”: {
“Attendee.ATT_full_name”: “ASC”
},
“include”: “Attendee.*,Ticket.*,Transaction.Payment_Method.PMD_name,Status.STS_code,Event.EVT_ID,Ticket.Datetime.*”,
“calculate”: “datetime_checkin_stati”,
“default_where_conditions”: “full_this_minimum_others”,
“caps”: “read_admin”
}

Body Parameters:
[]

Response Headers:
{
“Content-type”: “text\/html; charset=UTF-8”
}

Response Body:
(This one was very long. Is there anything I should share with you?)


Tony

  • Support Staff

March 5, 2020 at 2:30 am

Nothing out of the ordinary from the above, however, there are more requests sent that the above and it’s the response we’d need to see.

It’s probably easier to view if we can look at the REST API logs directly on your site, if that’s ok you can send temp login details over using this form:

https://eventespresso.com/send-login-details/

If you prefer not to thats fine but we’ll need to view the response from all of the requests sent when you log in with the app and get the error (there should be at least 4 requests added to the log when you log in)


djgore

March 5, 2020 at 8:54 am

Hi Tony,

I just filled out the form for you. Really appreciate your help with this!


djgore

March 5, 2020 at 11:44 am

Hi again,

I just wanted to check in and make sure you received the login details for the site.

We have a major event taking place tomorrow and we will need to use the app. Is it possible to have these issues resolved Today? I am concerned that if we try to use the Scanner on the app, that it will not register.

Thanks so much for your help.


Tony

  • Support Staff

March 5, 2020 at 1:40 pm

Hi there,

Yes we received your login credentials and I’ve spent some time going through the logs to try and spot any issues, but those all looked correct.

In the end I found that the requests sent from the Mobile app have notices/warnings thrown on them which means your server is set to display_errors even though you mentioned WP_DEBUG is disabled.

The notices are not thrown during ‘nomral’ requests which is why this was tough to track down, but here’s this is what is breaking the apps:

<br />
<b>Warning</b>:  rawurldecode() expects parameter 1 to be string, array given in <b>/wp-content/plugins/mainwp-child/class/class-mainwp-child.php</b> on line <b>1116</b><br />
<br />
<b>Warning</b>:  Cannot modify header information - headers already sent by (output started at /wp-content/plugins/mainwp-child/class/class-mainwp-child.php:1116) in <b>/wp-includes/rest-api/class-wp-rest-server.php</b> on line <b>1253</b><br />

That’s thrown at the beginning of the response and is not valid JSON, so the apps break.

If you disable MainWP do the apps work as expected?

You could set display_errors to off or 0 within PHP itself to stop the server displaying errors completely, that should prevent the above from being thrown on the request from the app.

Viewing 12 reply threads

The support post ‘EE4 Mobile App Error Message’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso