Google XML Sitemaps v. 3.2.3 WordPress Plugin Review

Site Map

This plugin generates XML file with special sitemap data. Such file helps to search engines like Google, Bing, Yahoo and Ask.com to index site content. Search crawlers using such sitemap data, much easier discover the whole site structure and retrieve its content more efficiently. “Google (XML) Sitemap Generator for WordPress” plugin supports all kinds of WordPress generated content. It also notifies major search engines (Google, Bing, Yahoo and Ask.com) every time you update your blog content.
Author: Arne BrachholdPlugin page at WordPress.orgPlugin Home Page

I use this plugin about a year and sure that it is very helpful. Recommend it to all WordPress blog owners.

Today I tried to check what is new in the version 3.2.3 and discovered that Arne missed that information at the plugin’s change log page for some reason. I’m sure he will fix it soon. For that time I decided to help you with this information. Thanks to Arne, he put some words about it into documentation.txt file in the plugin package:
“2010-04-02 3.2.3 Fixed that all pages were not included in the sitemap if the “Uncategorized” category was excluded”.

Comparing to version 3.2.2 we have these changes in the plugin installation package:

readme.txt – Plugin version number was changed and some minor text updates were made.
One of them: Link to “Upgrade to the PRO version to get extra features and professional support” was removed. It seems that opened to public “Google XML Sitemaps” becomes PRO and extra-featured for free. Thanks to Arne for his hard work.

sitemap-core.php –
1) version information was updated;
2) That early mentioned fix, when all pages were not included in the sitemap if the “Uncategorized” category was excluded, can be found in this file at lines 1702-1722.
I think, this information is enough to take a decision if you need install this version update or can skip it.

If you are a PHP or WordPress developer, it can be interesting for you to look into source code changes. I put it for you below.
Code before update:

$excludes=$this->GetOption('b_exclude');//Excluded posts$exclCats=$this->GetOption("b_exclude_cats");// Excluded catsif($exclCats&&count($exclCats)>0&&$this->IsTaxonomySupported()){$exPosts= get_objects_in_term($exclCats,"category");// Get all posts in excl. catsif(is_array($exPosts)&&count($exPosts)>0){//Merge it with the list of user excluded posts$excludes=array_merge($excludes,$exPosts);

$excludes=$this->GetOption('b_exclude');//Excluded posts and pages (user enetered ID)$exclCats=$this->GetOption("b_exclude_cats");// Excluded catsif($exclCats&&count($exclCats)>0&&$this->IsTaxonomySupported()){$excludedCatPosts= get_objects_in_term($exclCats,"category");// Get all posts in excl. cats. Unforttunately this also gives us pages, revisions and so on...//Remove the pages, revisions etc from the exclude by category list, because they are always in the uncategorized one.if(count($excludedCatPosts)>0){$exclPages=$wpdb->get_col("SELECT ID FROM `".$wpdb->posts."` WHERE post_type!='post' AND ID IN ('".implode("','",$excludedCatPosts)."')");$exclPages=array_map('intval',$exclPages);//Remove the pages from the exlusion list beforeif(count($exclPages)>0)$excludedCatPosts=array_diff($excludedCatPosts,$exclPages);//Merge the category exclusion list with the users oneif(count($excludedCatPosts)>0)$excludes=array_merge($excludes,$excludedCatPosts);}}

This entry was posted
on Saturday, April 3rd, 2010 at 02:20 and is filed under WordPress.
You can follow any responses to this entry through the RSS 2.0 feed.
You can skip to the end and leave a response. Pinging is currently not allowed.