Support

Home Forums Event Espresso Premium Download Receipt PDF not working

Download Receipt PDF not working

Posted: June 25, 2016 at 4:50 pm


Grace Combs

June 25, 2016 at 4:50 pm

Hello,
I am having an issue with the Receipt. I can view the HTML receipt but when I click download – nothing happens. It loads a blank page (safari) or gives me an error (chrome) and nothing is downloaded. Can you please help me figure out the source of this issue and how to fix it?

Thanks,

Grace


Tony

  • Support Staff

June 27, 2016 at 4:42 am

Hi Grace,

If you just see a blank screen its likely a fatal error is being thrown.

If you enable WP_DEBUG and re-test download the PDF it should show you what the error is. If you can post that here we can help find the cause.

Or if you have access or the servers error logs you may find the error there without needing to enable WP_DEBUG.


Grace Combs

June 27, 2016 at 12:19 pm

I Checked the errors logs on my server. Nothing is showing up in reference to this. I do get this error when I uses chrome though.

The theresponseusa.com page isn’t working

theresponseusa.com is currently unable to handle this request.
HTTP ERROR 500

Please advise.


Lorenzo Orlando Caum

  • Support Staff

June 27, 2016 at 12:35 pm

Hi Grace,

Could you re-test this with WP debug with debug log on. The debug log should then record the error and provide more specific information.

Here are the steps:

Add the constant in the following link to your wp-config.php file replacing any existing debug constant:

https://gist.github.com/lorenzocaum/848801a1173be464fbe7#file-gistfile1-php

The wp-config.php file can be found in the WordPress root which is where the wp-admin, wp-content, and other files and folders for WordPress resides.

Then please try to trigger the error and you should may something on the screen. Could you copy and paste that here into a reply?

If you do not see an error on your screen, then please browse to this location using your SFTP or FTP client (e.g. FileZilla, Cyberduck):

/wp-content/debug.log

You should see an error recorded within the file. Please copy and paste that here in a reply.

Then go ahead and immediately deactivate WordPress debugging by removing the constant that was recently added (or setting it to false) and saving changes:

https://gist.github.com/lorenzocaum/848801a1173be464fbe7#gistcomment-1239850


Lorenzo


Grace Combs

June 27, 2016 at 1:08 pm

Here is the error displaying in my error log.

[27-Jun-2016 19:02:32 UTC] PHP Fatal error: Call to undefined function mb_internal_encoding() in /home/theresponseusa/public_html/wp-content/plugins/event-espresso-core-reg/core/third_party_libs/dompdf/dompdf_config.inc.php on line 329


Lorenzo Orlando Caum

  • Support Staff

June 27, 2016 at 2:40 pm

Thanks Grace. Are you managing the server yourself?

If so, could you turn on mbstring?

http://php.net/manual/en/ref.mbstring.php

If not, then please ask the web host to enable mbstring and that should resolve the issue.


Lorenzo


Grace Combs

June 27, 2016 at 4:14 pm

It appears as if mbstring is enabled. Here is exactly what it says in my php configuration.

mbstring.detect_order auto **DEFAULT**, Click to Edit
mbstring.encoding_translation Off **DEFAULT**, Click to Edit
mbstring.func_overload 0 **DEFAULT**, Click to Edit
mbstring.http_input auto **DEFAULT**, Click to Edit
mbstring.http_output SJIS **DEFAULT**, Click to Edit
mbstring.internal_encoding EUC-JP **DEFAULT**, Click to Edit
mbstring.language Japanese **DEFAULT**, Click to Edit
mbstring.substitute_character none **DEFAULT**, Click to Edit

Do any of these settings need to be changed?


Tony

  • Support Staff

June 27, 2016 at 4:20 pm

Hi Grace,

Those are individual settings for mbstring, but the module itself may not have been loaded, look for something like:

extension=php_mbstring.dll

That would normally be within your php.ini file but some hosts also allow you to enable/disable this within your control panel.

You may find it within the file but it could have a ; at the beginning to comment out the line, like this:

;extension=php_mbstring.dll

If so remove the ; and save the file, note you may also need to restart apache if this is the case.


Grace Combs

June 27, 2016 at 5:30 pm

I removed the ; from the public_html php.ini file but nothing appears to be different. The file still doesn’t download. Does it need time to propagate on the server?


Tony

  • Support Staff

June 28, 2016 at 5:07 am

No but you may need to restart Apache for the changes to take effect and the module to load.

You can either restart apache or just reload its config (no downtime), take a look here:

http://askubuntu.com/questions/6358/how-do-you-restart-apache

Note that if you have any errors in your config file apache will fail to restart, if you are unsure I would recommend contacting your host to do this for you. Also I’m not sure which type of hosting you are using but if you are using a shared server you may not have access to do this, in which case you will need to contact your host anyway.


Grace Combs

June 28, 2016 at 5:37 pm

Hello,

I have restarted my apache and checked my error logs. The only error is with your plugin. The problem is still not fixed. The error is still showing up and the file still won’t download.

Thanks,

Grace


Tony

  • Support Staff

June 29, 2016 at 4:28 am

If it’s the same error:

PHP Fatal error: Call to undefined function mb_internal_encoding()

Then mb_string is not loaded on the server.

I would recommend contacting your host and have them make sure mb_String is loading on the server.

If it’s a different error please post is here so we can investigate.


Grace Combs

June 29, 2016 at 12:56 pm

Contacted my host and they said it wasn’t loaded onto the server. I rebuilt my apache with the mb_string enabled and everything is working perfectly now.

Just for reference for anyone else having this issue I am running on a Godaddy VPS. It looks like their standard apache load out does not load mb_string.

Thanks!


Tony

  • Support Staff

June 29, 2016 at 3:11 pm

Great, thank you for keeping us updated 🙂

If you have any further problems please let us know.

The support post ‘Download Receipt PDF not working’ 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