Support

Home Forums Event Espresso Premium Warning: Missing argument 2 for udesign_more_link()

Warning: Missing argument 2 for udesign_more_link()

Posted: December 14, 2014 at 3:18 pm

Viewing 6 reply threads


Guillaume Goyette

December 14, 2014 at 3:18 pm

I am using
Wordpress 4.0.1
Event Espresso 4.4.6.p
And the latest version of my theme : U-Design
http://themeforest.net/item/udesign-responsive-wordpress-theme/253220

I have a php warning in my event page (wich is translated in french)
http://carrefourfamilialsj.org/evenements/

The warning is :

Warning: Missing argument 2 for udesign_more_link() in /home/carrefourfamilialsj/carrefourfamilialsj.org/wordpress/wp-content/themes/u-design/functions.php on line 1715

I asked help to the theme developer. Fist he asked me to check if my wordpress was in debug mode : it was not.

Then he answered me this :

If you have disabled debug in WordPress, than this issue reporting is being caused by that plugin. Normally, “warning” level errors would not appear on a site. So, you’ll want talk to the developer of the plugin to clarify why they have left a development system active in production code.

Now, regarding the warning message, line 1715 refers to the function used for translations of the WordPress <!–more–>. I have no idea why that plugin would be calling that function, as it’s not involved in the generation of breadcrumbs normally. Another good question to ask the developer of that plugin.

Here a screen shot of his answer ;
https://nimbus.everhelper.me/client/notes/share/132575/7Zkq1IhfFR4Bc5bMu6PCQe4IRFZAZIoc/

Do you know how I can remove this warning ??

Thanks


Tony

  • Support Staff

December 15, 2014 at 8:10 am

Hi,

Would it be possible for you to send us a copy of that theme so we can investigate this a little?

Warning: Missing argument 2 for udesign_more_link() in /home/carrefourfamilialsj/carrefourfamilialsj.org/wordpress/wp-content/themes/u-design/functions.php on line 1715

This is being caused by the udesign_more_link() function from within the theme. I’m guessing its hooking into ‘the_content_more_link’ but will need to dig into the code a little more to troubleshoot.

If you have disabled debug in WordPress, than this issue reporting is being caused by that plugin. Normally, “warning” level errors would not appear on a site. So, you’ll want talk to the developer of the plugin to clarify why they have left a development system active in production code.

This is actually not an issue with Event Espresso, it would appear your server has error_reporting enabled so regardless of WP_Debug being enabled or not, your server will display the errors/warnings thrown.

There are various ways fix this, you can usually set this from within cPanel (look for error_reporting, usually within PHP settings) although it depends on your host.

It is also possible to set this within your wp-config.php file using something like:

@ini_set( 'display_errors', 0 );

Which tells your server (not Event Espresso) to stop displaying errors.

Now, regarding the warning message, line 1715 refers to the function used for translations of the WordPress . I have no idea why that plugin would be calling that function, as it’s not involved in the generation of breadcrumbs normally. Another good question to ask the developer of that plugin.

Event Espresso hooks into the_content() (and other hooks) to output the event information. If the above function is hooking into ‘the_content_more_link’ then that filter is also called.

If we can take a look at the theme code we can provide a little more information, however the code I posted above will remove the warning from the site (although it does not fix the actual problem)


Guillaume Goyette

December 16, 2014 at 11:32 am

I confirm that the wp-config add is removing the warning !

I suppose my other post is not showing up yet because of the link (to give you my theme files)

Thanks again


Tony

  • Support Staff

December 16, 2014 at 12:31 pm

Hi,

I suppose my other post is not showing up yet because of the link (to give you my theme files)

I’m not sure what this means? Have you posted a reply but it is not appearing here?

If you have hosted the theme files please send the link to download to this email address:

support[at]eventespresso.com

Be sure to include a reference to this thread so we can link the two together.


Guillaume Goyette

December 16, 2014 at 1:58 pm

Sorry for the confusion…

Yes, I have tried to post a link with my theme files… I dont know if I did really submit it or if it whent to the spam

I will send you a email with the zip of the theme

Thanks again


Tony

  • Support Staff

December 17, 2014 at 3:57 am

Hi,

Thank you for sending the theme, we are investigating this and will update this thread with any findings.


Josh

  • Support Staff

November 3, 2015 at 2:56 pm

Update: The latest update of Event Espresso 4 includes an update to the the_content_more_link filter signature to avoid the Missing argument 2 warning.

Viewing 6 reply threads

The support post ‘Warning: Missing argument 2 for udesign_more_link()’ 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