Support

Home Forums Event Espresso Premium Event Espresso v3.1.37.11.P crashes entire site – including Admin

Event Espresso v3.1.37.11.P crashes entire site – including Admin

Posted: February 14, 2017 at 6:01 pm

Viewing 26 reply threads


peter

February 14, 2017 at 6:01 pm

Below is the error I get upon activating Event Espresso v3.1.37.11.P
I get this error on both front and back end:

Warning: require_once(/paypal_vars.php): failed to open stream: No such file or directory in /home/content/85/8132085/html/wp2/wp-content/uploads/espresso/gateways/paypal/init.php on line 5

Fatal error: require_once(): Failed opening required ‘/paypal_vars.php’ (include_path=’.:/usr/local/php5_4/lib/php’) in /home/content/85/8132085/html/wp2/wp-content/uploads/espresso/gateways/paypal/init.php on line 5

We don’t even use paypal.

Please advise.

Thanks!


Tony

  • Support Staff

February 15, 2017 at 4:26 am

Hi Peter,

On your server within /wp-content/uploads/espresso/gateways/ it looks like you have a paypal directory. Because of that directory Event Espresso is trying to load its paypal gateway files from that location.

Using FTP (or a file manager if you hosts provides one) navigate to /root/wp-content/uploads/espresso and rename the paypal directory to something else, ‘paypal-temp’ will be fine.

Then check if you can activate EE3.

You could delete that directory if preferred but I have no idea why its been added on your site (it must have been done manually as EE will not create it).


peter

February 15, 2017 at 12:56 pm

That didn’t work – which is bizarre.
I also renamed the /paypal-pro/ folder and still get the same exact warning.

I even removed the paypal gateway folder from the zip file and re-uploaded it and still get the same errors.

I’m confused.
Please advise.


Tony

  • Support Staff

February 15, 2017 at 1:02 pm

The only way you can still get the same error is if there is still a PayPal directory in uploads.

Are you 100% you in the correct location?


peter

February 15, 2017 at 1:35 pm

I’m 100% sure.

After searching all the code for where “paypal_vars.php” occurred (which is only in “/paypal/” folder) I asked myself the same question: How could this be?

When move that same plugin OUT of the plugins folder and the site doesn’t crash – and I know I’m working in the correct/live folder because after moving it out there is no EE functionality.

I spent an hour doing variations on this (removing the “paypal” folder, renaming the paypal folder, removing the paypal folder from the zip file and re-uploading), and I get that error if and only if this new version of the plugin is activated. It doesn’t seem to matter how I’ve “removed” the paypal gateway folder.

It has me pulling my hair out.

Any other debugging suggestions?


Tony

  • Support Staff

February 15, 2017 at 1:43 pm

It sounds like you’re removing the PayPal folder from /wp-content/plugins/event-espresso/gateways/ unless Im misunderstanding the above?

Did you look within /wp-content/uploads/espresso/gateways/?


peter

February 15, 2017 at 2:23 pm

Gadzooks – you’re right, I was not removing the correct one.

OK, so I just removed the one in
/wp-content/uploads/espresso/gateways/
And now I get this:

Warning: require_once(/check_payment_vars.php) [function.require-once]: failed to open stream: No such file or directory in /home/content/85/8132085/html/wp2/wp-content/uploads/espresso/gateways/check/init.php on line 5

<code>Fatal error: require_once() [function.require]: Failed opening required '/check_payment_vars.php' (include_path='.:/usr/local/php5_3/lib/php') in /home/content/85/8132085/html/wp2/wp-content/uploads/espresso/gateways/check/init.php on line 5</code>

So I removed the "check" gateway from
<code>/wp-content/uploads/espresso/gateways/</code>
 and then get these warnings inline on the website:

Warning: ltrim() expects parameter 1 to be string, array given in /home/content/85/8132085/html/wp2/wp-includes/wp-db.php on line 2723

Warning: mysql_query() expects parameter 1 to be string, array given in /home/content/85/8132085/html/wp2/wp-includes/wp-db.php on line 1879

Warning: preg_match() expects parameter 2 to be string, array given in /home/content/85/8132085/html/wp2/wp-includes/wp-db.php on line 1820

Warning: preg_match() expects parameter 2 to be string, array given in /home/content/85/8132085/html/wp2/wp-includes/wp-db.php on line 1822`


peter

February 15, 2017 at 2:27 pm

Don’t know what went wrong with formatting, I hope this is better:

You’re right, I was not removing the correct one.
So I just removed the one in

/wp-content/uploads/espresso/gateways/

And now I get this:

Warning: require_once(/check_payment_vars.php) [function.require-once]: failed to open stream: No such file or directory in /home/content/85/8132085/html/wp2/wp-content/uploads/espresso/gateways/check/init.php on line 5

Fatal error: require_once() [function.require]: Failed opening required '/check_payment_vars.php' (include_path='.:/usr/local/php5_3/lib/php') in /home/content/85/8132085/html/wp2/wp-content/uploads/espresso/gateways/check/init.php on line 5

So I removed the “check” gateway from

/wp-content/uploads/espresso/gateways/

and then get these warnings inline on the website:

Warning: ltrim() expects parameter 1 to be string, array given in /home/content/85/8132085/html/wp2/wp-includes/wp-db.php on line 2723
Warning: mysql_query() expects parameter 1 to be string, array given in /home/content/85/8132085/html/wp2/wp-includes/wp-db.php on line 1879
Warning: preg_match() expects parameter 2 to be string, array given in /home/content/85/8132085/html/wp2/wp-includes/wp-db.php on line 1820
Warning: preg_match() expects parameter 2 to be string, array given in /home/content/85/8132085/html/wp2/wp-includes/wp-db.php on line 1822


Tony

  • Support Staff

February 15, 2017 at 2:37 pm

You will get the Fatal error: require_once() errors for any gateway directories that you have in /uploads/espresso/gateways/ that are empty or if EE can’t read the file.

Where do you see the other warnings? Admin or front end?

Do they happen with only Event Espresso running and all other plugins de-activated?


Josh

  • Support Staff

February 15, 2017 at 2:45 pm

One thing you could do that should help is go in and rename the
/wp-content/uploads/espresso/gateways/ folder
to be:
/wp-content/uploads/espresso/gateways-old/


peter

February 15, 2017 at 4:07 pm

I renamed the folder to “gateways-old”.
I deactivated all plugins except EE and EE-calendar.
I set the theme to simple default TwentySixteen.

I get these errors:

Warning: ltrim() expects parameter 1 to be string, array given in /home/content/85/8132085/html/wp2/wp-includes/wp-db.php on line 2723

Warning: mysql_query() expects parameter 1 to be string, array given in /home/content/85/8132085/html/wp2/wp-includes/wp-db.php on line 1879

Warning: preg_match() expects parameter 2 to be string, array given in /home/content/85/8132085/html/wp2/wp-includes/wp-db.php on line 1820

Warning: preg_match() expects parameter 2 to be string, array given in /home/content/85/8132085/html/wp2/wp-includes/wp-db.php on line 1822


peter

February 15, 2017 at 4:23 pm

I just noticed this “notice” in the admin area at the top of the page:

The Atos gateway has been removed from Event Espresso core in 3.1.37. Please download and upload the Atos gateway to /wp-content/uploads/espresso/gateways. Please see our documentation for more information.

Could this be related?


Tony

  • Support Staff

February 16, 2017 at 4:00 am

Could this be related?

No it’s not related.

Where do you see the other warnings? Admin or front end?


Josh

  • Support Staff

February 16, 2017 at 12:46 pm

It’d also be good to check to see if you’re getting the PHP warnings while the Event Espresso plugins are deactivated.


peter

February 16, 2017 at 12:54 pm

These:

Warning: require_once(/paypal_vars.php)

Were on both back and front end and killed the site (including the admin) entirely such that I had to FTP in to remove the plugin to get the site working again.

These:

Warning: ltrim() expects parameter 1 to be string, array given

Were only on the front end, inline on the page. Ugly, and the code didn’t work, but it didn’t crash the site.

There are no problems with the site when EE is deactivated.


Josh

  • Support Staff

February 16, 2017 at 1:28 pm

Are you still getting the Warning: require_once(/paypal_vars.php) with a fresh copy of Event Espresso 3 installed and the /wp-content/uploads/espresso/gateways folder renamed?

You can eliminate the other PHP warnings by adding this line of code to your wp-config.php file:

@ini_set( 'display_errors', 0 );


peter

February 16, 2017 at 2:04 pm

No Josh,
I’m only getting these:

Warning: ltrim() expects parameter 1 to be string, array given in /home/content/85/8132085/html/wp2/wp-includes/wp-db.php on line 2723

But it also doesn’t display the calendar or the event listings.
So suppressing the warnings isn’t sufficient.

– pvg


Josh

  • Support Staff

February 16, 2017 at 2:14 pm

The warnings might have nothing to do with the calendar not displaying. Where can we view the calendar and event list pages on your website so we can investigate further?


peter

February 16, 2017 at 2:55 pm

On the LIVE site I currently have the old plugin activated because the owner’s income relies on this site being up and running.

So, I have made copy of the site over here, with all other plugins turned off (that’s why you’ll see some broken short-codes on that page):

http://moon-acre-farm.com/safefood/food-safety-manager-class/ (class listing not showing)
http://moon-acre-farm.com/safefood/ (calendar not showing in right-hand widget area)

Here’s the live site with and older plugin (it has a bug I’m working around until we get the new one working):
http://allaboutsafefood.com/food-safety-manager-class/ (class listing)
http://allaboutsafefood.com/ (calendar in right-hand widget area)

Let me know if you want credentials to log into wordpress. I can even install a file manager plugin so you can looks at files, upload, whatever. if you do, let me know where/how to send those wp credentials.


Josh

  • Support Staff

February 16, 2017 at 4:39 pm

OK so I wonder how the data was copied over from the live site to the testing site. Was the data migrated using a tool like WP DB Migrate Pro or similar? If not, that may be why you’re seeing the errors that are related to the wpdb class.


peter

February 16, 2017 at 4:46 pm

And I used UpdraftsPlus Backup plugin to do the move.

The behavior you see on the test site, here:
http://moon-acre-farm.com/safefood/
Is the same behavior I was seeing on the live site.

It was breaking on the live site first and I only made the test site so that I could leave it up for you to see and poke if you wanted to.


Josh

  • Support Staff

February 16, 2017 at 4:55 pm

The calendar short code won’t display from a WP text widget, unless you set all pages to manually load in the Calendar plugin’s scripts and styles.

Here’s what you can do instead:

Option 1) Use the Espresso Calendar widget

Option 2) Put the Calendar short code in a page template by following this section of the documentation:

https://eventespresso.com/wiki/events-calendar-add-on/#ee3customizations


peter

February 16, 2017 at 5:04 pm

I have that calendar addon installed.
And it was showing in the sidebar.
So, this isn’t the problem.
The problem is that the events that used to show up like they don on this page:
http://allaboutsafefood.com/food-safety-manager-class/

Don’t show up with the new plugin, the look like this:
http://moon-acre-farm.com/safefood/food-safety-manager-class/


Tony

  • Support Staff

February 17, 2017 at 3:54 am

Within /wp-content/uploads/espresso/ there should be a ‘templates’ directory, does it have any files at all within that directory?

If so rename the templates directory to templates-old and see if the above page works correctly.


peter

February 17, 2017 at 5:58 pm

Hoorah! That worked. Thanks all!

So, now that there are no templates, the page isn’t that readable.
With these changes in place, what is the recommended way to format the events in the event list? CSS?

Also, the calendar used to display in the side bar just fine on the home page?
The page Josh linked to regarding this mentions customizing templates – but we just disabled them – or am I missing something?


Josh

  • Support Staff

February 17, 2017 at 6:17 pm

Yes, CSS is a good way to re-style any html page.

Also, the calendar used to display in the side bar just fine on the home page?

There would have had to have been some customizations to make that calendar display in the sidebar. By default the calendar short code will not load it’s scripts if it’s not in the actual WordPress page content.

The page I linked to mentions adding the code to the WordPress page template, not Event Espresso templates. So you if want to make the calendar short code work within a widget, you add this code to your theme’s header.php file, near the top of the file before it calls the wp_head() function:

global $is_espresso_calendar;
$is_espresso_calendar = TRUE;


peter

February 22, 2017 at 3:42 pm

Thank you!
We’re up and running again!

Viewing 26 reply threads

The support post ‘Event Espresso v3.1.37.11.P crashes entire site – including Admin’ 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