Dagon Design Sitemap Generator
Maybe a mistake in the code (3 posts)

  1. soleil_levant
    Posted 5 years ago #


    With WP 3.0.1 and Dagon 3.15, I get this error (WP_DEBUG on) :

    Notice: Use of undefined constant ddsg_language - assumed 'ddsg_language' in /var/www/vhosts/capdelahague.org/httpdocs/wp-content/plugins/sitemap-generator/sitemap-generator.php on line 45

    To fix it in sitemap-generator.php, I replace :

    $ddsg_lang_file = trim(get_option(ddsg_language));

    with :

    $ddsg_lang_file = trim(get_option('ddsg_language'));

    because the argument of get_option() must be a string.

    Do you agree with me ?


  2. soleil_levant
    Posted 5 years ago #

    In an other way, when I activate debug mode on WP, I get some warnings because of deprecated argument in function add_options_page(). These warnings suggest to replace "users level" with "roles and capabilities" and are produced by some plugins including yours.

    I suggest you replace line 58 :

    add_options_page('Dagon Design Sitemap Generator', 'DDSitemapGen',
    8, __FILE__, 'ddsg_options_page');


    add_options_page('Dagon Design Sitemap Generator', 'DDSitemapGen', 'manage_options', __FILE__, 'ddsg_options_page');

    I think it's the good way.

  3. a1wsn
    Posted 5 years ago #

    Thanks, if you find other fixes for this plugin please share them here :)

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic