Support

Home Forums Event Espresso Premium Fatal Error

Fatal Error

Posted: January 19, 2017 at 2:55 am


Bosworthsgc

January 19, 2017 at 2:55 am

Hi

I am adding a new event and am getting the following error when viewing the event

Fatal error: Uncaught TypeError: Argument 1 passed to EEH_Schema::add_json_linked_data_for_event() must be an instance of EE_Event, string given, called in /wp-content/plugins/event-espresso-core-reg/core/EE_Front_Controller.core.php on line 616 and defined in /wp-content/plugins/event-espresso-core-reg/core/helpers/EEH_Schema.helper.php:25 Stack trace: #0 /wp-content/plugins/event-espresso-core-reg/core/EE_Front_Controller.core.php(616): EEH_Schema::add_json_linked_data_for_event(”) #1 /wp-includes/class-wp-hook.php(298): EE_Front_Controller->wp_print_scripts(”) #2 /wp-includes/class-wp-hook.php(323): WP_Hook->apply_filters(NULL, Array) #3 /homepages/7/d588332988/htdocs/clickandbuilds/Boswo in /wp-content/plugins/event-espresso-core-reg/core/helpers/EEH_Schema.helper.php on line 25

Can you help please?

Thanks

  • This topic was modified 2 years, 10 months ago by  Tony. Reason: remove server path


Tony

  • Support Staff

January 19, 2017 at 4:49 am

Hi there,

I’ll create a ticket for our developers to investigate this, it looks like something is interfering with the $post object on your site.

If you preview the page using a default theme such as twenty fourteen, does the same happen then?

You can do that without switch the theme on the front end using a plugin such as Theme Test Drive


Bosworthsgc

January 19, 2017 at 6:02 am

Hi again

I tried Theme Test Drive but as soon as I selected any other them it crashed with another error message on the front end
Fatal error: Uncaught Error: Call to undefined function theme_locals() in /wp-content/themes/theme53937/includes/widgets/my-social-widget.php:6 Stack trace: #0 /wp-includes/class-wp-widget-factory.php(106): My_SocialNetworksWidget->My_SocialNetworksWidget() #1 /wp-includes/widgets.php(113): WP_Widget_Factory->register(‘My_SocialNetwor…’) #2 /wp-content/plugins/cherry-plugin/includes/widgets/register-widgets.php(26): register_widget(‘My_SocialNetwor…’) #3 /wp-includes/class-wp-hook.php(298): cherry_load_widgets(”) #4 /wp-includes/class-wp-hook.php(323): WP_Hook->apply_filters(NULL, Array) #5 /homepages/7/d588332988/htdocs/c in /wp-content/themes/theme53937/includes/widgets/my-social-widget.php on line 6

Just an additional point I did build our site on the domain http://www.letsgrowletsgo.co.uk and moved it over yesterday to http://www.bosworthsgc.co.uk using updraftplus premium plugin – dont know if that makes any difference

The only way I can then revert back is to FTP in to remove the plugin

Thanks

  • This reply was modified 2 years, 10 months ago by  Tony. Reason: remove server path


Tony

  • Support Staff

January 19, 2017 at 6:13 am

That second fatal error is from the theme and based on the theme I’m fairly sure the original fatal is from the theme also (although I could be wrong)

Can you send me a copy of the theme so I can install it locally?

If so you’ll need to host the original zip file somewhere (dropbox or the media uploader through your site for example) and post a link I can use to download it.


Bosworthsgc

January 19, 2017 at 6:14 am

I think I have the theme from the back up I did prior to moving the site – would this help?


Tony

  • Support Staff

January 19, 2017 at 6:23 am

I’m not sure what you mean?

I’m looking for a copy of the theme your currently using so I can install it locally and see if I get the fatal error. Once I can reproduce we can find out whats causing the error.


Bosworthsgc

January 19, 2017 at 6:27 am

I have downloaded it. It is a paid for theme

Do you have an email I can paste the link for you

Thanks


Tony

  • Support Staff

January 19, 2017 at 6:30 am

Sure, you can use support[at]eventespresso.com


Bosworthsgc

January 19, 2017 at 7:05 am

Ive actually found the cause

It seems to be a rogue plugin called Show Future Posts on Single Post

Disactivating it solves the problem

I will leave it a while and then delete it


Josh

  • Support Staff

January 19, 2017 at 8:23 am

Thanks for the update. So it looks like the Show Future Posts on Single Post plugin strips away the event information from the $post object by the time the wp_print_scripts hook is fired, which is where Event Espresso adds the new feed for event data for SEO (JSON-LD).

We can add some error checking there. So if you were to reactivate Show Future Posts, there won’t be a fatal error anymore. However, the event post will not include the JSON-LD data since the data gets removed by that other plugin.


Josh

  • Support Staff

January 26, 2017 at 8:50 am

update: Event Espresso 4.9.27.p adds some error proofing to avoid the Fatal error you saw the Show Future Posts on Single Post plugin was activated.

The support post ‘Fatal Error’ 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.

Support forum for Event Espresso 3 and Event Espresso 4.
Documentation for EE3 and EE4
Documentation for Event Espresso 3

Documentation for Event Espresso 4

Status: closed

Updated by  Josh 2 years, 9 months ago ago

Topic Tags

Notifications

This topic is: not resolved
Do NOT follow this link or you will be banned from the site!
[for="input_96_5_3"]
[for="input_96_5_3"]
[gravityform id=96 title=false description=false]
  • This field is for validation purposes and should be left unchanged.
[i]
[i]
[gravityform id=69 title=false description=false]
  • This field is for validation purposes and should be left unchanged.