Page 1 of 1

Bugfix: Google Sitemap Plugin and draft static pages

Posted: Sun Apr 16, 2006 5:53 pm
by frAgor
(I do not know which forum to use for bugfixes and not bug reports, so I simply use this one ;-) )

I wondered why google listed a static page from my blog with state draft.
This was caused by the SQL query in serendipity_event_google_sitemap.php.

So please change (lines 285 - 290) from

Code: Select all

$static_pages = serendipity_db_query(
        'SELECT permalink, '.$sqlnullfunction.'(timestamp, 0)
         FROM '.$serendipity['dbPrefix'].'staticpages
         WHERE CHAR_LENGTH(pass)=0',
    false, 'assoc');
to

Code: Select all

$static_pages = serendipity_db_query(
        'SELECT permalink, '.$sqlnullfunction.'(timestamp, 0)
         FROM '.$serendipity['dbPrefix'].'staticpages
         WHERE CHAR_LENGTH(pass)=0 AND publishstatus != 0',
    false, 'assoc');
Thank you,
Markus

Re: Bugfix: Google Sitemap Plugin and draft static pages

Posted: Mon Apr 17, 2006 9:12 pm
by garvinhicking
Thanks a lot! Fixed in CVS! :)

Best regards,
Garvin