Version Description
Download this release
Release Info
Developer | arnee |
Plugin | Google XML Sitemaps |
Version | 4.0.7 |
Comparing to | |
See all releases |
Code changes from version 4.0.6 to 4.0.7
- documentation.txt +32 -26
- readme.txt +33 -19
- screenshot-1.gif +0 -0
- screenshot-1.png +0 -0
- screenshot-2.gif +0 -0
- screenshot-2.png +0 -0
- screenshot-3.gif +0 -0
- screenshot-3.png +0 -0
- sitemap-core.php +42 -9
- sitemap-loader.php +11 -43
- sitemap-ui.php +10 -2
- sitemap.php +3 -3
documentation.txt
CHANGED
@@ -50,30 +50,30 @@ Release History:
|
|
50 |
2005-06-05 2.0a Beta: Real Plugin! Static file generation, Admin UI
|
51 |
2005-06-05 2.0 Various fixes, more help, more comments, configurable filename
|
52 |
2005-06-07 2.01 Fixed 2 Bugs: 147 is now _e(strval($i)); instead of _e($i); 344 uses a full < ?php instead of < ?
|
53 |
-
|
54 |
2005-06-07 2.1 Correct usage of last modification date for cats and archives (thx to Rodney Shupe (http://www.shupe.ca/))
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
2005-06-07 2.11 Fixed bug with hardcoded table table names instead of the $wpd vars
|
59 |
2005-06-07 2.12 Changed SQL Statement of the categories to get it work on MySQL 3
|
60 |
2005-06-08 2.2 Added language file support:
|
61 |
-
|
62 |
-
|
63 |
-
2005-06-14 2.5
|
64 |
Added support for Google Ping
|
65 |
Added the minimum Post Priority option
|
66 |
Added Spanish Language File by César Gómez Martín (http://www.cesargomez.org/)
|
67 |
Added Italian Language File by Stefano Aglietti (http://wordpress-it.it/)
|
68 |
Added Traditional Chine Language File by Kirin Lin (http://kirin-lin.idv.tw/)
|
69 |
-
2005-07-03 2.6
|
70 |
Changed the home URL to have a slash at the end
|
71 |
Required admin-functions.php so the script will work with external calls, wp-mail for example
|
72 |
Added support for other plugins to add content to the sitemap via add_filter()
|
73 |
-
2005-07-20 2.7
|
74 |
Added Simplified Chinese Language Files by june6 (http://www.june6.cn/)
|
75 |
Added Swedish Language File by Tobias Bergius (http://tobiasbergius.se/)
|
76 |
-
2006-01-07 3.0b
|
77 |
Added support to use the Popularity Contest plugin by Alex King to calculate post priority
|
78 |
Added Button to restore default configuration
|
79 |
Added several links to homepage and support
|
@@ -84,17 +84,17 @@ Release History:
|
|
84 |
Improved speed and optimized settings handling
|
85 |
Improved user-interface
|
86 |
Recoded plugin architecture which is now fully OOP
|
87 |
-
2006-01-07 3.0b1
|
88 |
Readded support for tools like w.Bloggar
|
89 |
Fixed "doubled-content" bug with WP2
|
90 |
Added xmlns to enable validation
|
91 |
-
2006-03-01 3.0b3
|
92 |
More caching
|
93 |
Better support for Popularity Contest and WP 2.x
|
94 |
-
2006-11-16 3.0b4
|
95 |
Decreased memory usage which should solve timeout and memory problems
|
96 |
Updated namespace to support YAHOO and MSN
|
97 |
-
2007-01-19 3.0b5
|
98 |
WP 2 Design
|
99 |
YAHOO notification
|
100 |
New status report, removed ugly logfiles
|
@@ -108,12 +108,12 @@ Release History:
|
|
108 |
- Glenn Nicholas (http://publicityship.com.au)
|
109 |
Improved file handling, thanks to VJTD3 (http://www.VJTD3.com)
|
110 |
WP 2.1 improvements
|
111 |
-
2007-01-23 3.0b6
|
112 |
Removed the usage of REQUEST_URI since it not correct in all environments
|
113 |
Fixed that sitemap.xml.gz was not compressed
|
114 |
Added compat function "stripos" for PHP4 (Thanks to Joseph Abboud!)
|
115 |
Streamlined some code
|
116 |
-
2007-05-17 3.0b7
|
117 |
Small enhancements, removed stripos dependency and the added compat function
|
118 |
Added check to not build the sitemap if importing posts
|
119 |
Fixed missing domain parameter for translator name
|
@@ -121,38 +121,38 @@ Release History:
|
|
121 |
Fixed wrong XSLT location (Thanks froosh)
|
122 |
Added Ask.com notification
|
123 |
Removed unused javascript
|
124 |
-
2007-07-22 3.0b8
|
125 |
Plugin will be loaded on "init" instead of direclty after the file has been loaded.
|
126 |
Added support for robots.txt modification
|
127 |
Switched YAHOO ping API from YAHOO Web Services to the "normal" ping service which doesn't require an app id
|
128 |
Search engines will only be pinged if the sitemap file has changed
|
129 |
-
2007-09-02 3.0b9
|
130 |
Now using post_date_gmt instead of post_date everywhere
|
131 |
Fixed archive bug with static pages (Thanks to Peter Claus Lamprecht)
|
132 |
Fixed some missing translation domains, thanks to Kirin Lin!
|
133 |
Added Czech translation files for 2.7.1, thanks to Peter Kahoun (http://kahi.cz)
|
134 |
-
2007-09-04 3.0b10
|
135 |
Fixed bug with empty URLs in sitemap
|
136 |
Repaired GET building
|
137 |
Added more info on debug mode
|
138 |
-
2007-09-23 3.0b11
|
139 |
Uses MUCH less memory
|
140 |
Fixed really stupid bug with search engine pings
|
141 |
Option to set how many posts will be included
|
142 |
-
2007-09-24 3.0
|
143 |
Removed useless functions
|
144 |
-
2007-11-03 3.0.1
|
145 |
Fixed undefined translation strings
|
146 |
Added "safemode" for SQL which doesn't use unbuffered results (old style)
|
147 |
Added option to run the building process in background using wp-cron
|
148 |
Removed unnecessary function_exists, Thanks to user00265
|
149 |
Added links to test the ping if it failed.
|
150 |
-
2007-11-25 3.0.2
|
151 |
Added option to exclude pages or post by ID
|
152 |
Restored YAHOO ping service with API key since the other one is to unreliable. (see 3.0b8)
|
153 |
2007-11-28 3.0.2.1 Fixed wrong XML Schema Location (Thanks to Emanuele Tessore)
|
154 |
Added Russian Language files by Sergey http://ryvkin.ru
|
155 |
-
2007-12-30 3.0.3
|
156 |
Removed some hooks which rebuilt the sitemap with every comment
|
157 |
2008-03-30 3.0.3.1 Added compatibility CSS for WP 2.5
|
158 |
2008-04-28 3.0.3.2 Improved WP 2.5 handling
|
@@ -169,7 +169,7 @@ Release History:
|
|
169 |
Fixed background building bug in WP 2.1
|
170 |
Removed auto-update plugin link for WP < 2.5
|
171 |
2008-05-22 3.1 Marked as 3.1 stable, updated documentation
|
172 |
-
2008-05-27 3.1.0.
|
173 |
Enabled the option to include following pages of multi-page posts
|
174 |
Script tries to raise memory and time limit if active
|
175 |
2008-12-21 3.1.1 Fixed redirect issue if wp-admin is rewritten via mod_rewrite, thanks to macjoost
|
@@ -301,6 +301,12 @@ Release History:
|
|
301 |
Don't gzip if behind Varnish
|
302 |
Improved compatibility with caches
|
303 |
Ping on post edit
|
|
|
|
|
|
|
|
|
|
|
|
|
304 |
|
305 |
Todo:
|
306 |
==============================================================================
|
@@ -345,7 +351,7 @@ function your_pages() {
|
|
345 |
$generatorObject = &GoogleSitemapGenerator::GetInstance();
|
346 |
if($generatorObject!=null) $generatorObject->AddUrl("http://blog.uri/tags/hello/",time(),"daily",0.5);
|
347 |
}
|
348 |
-
add_action("sm_buildmap","your_pages");
|
349 |
|
350 |
Parameters:
|
351 |
- The URL to the page
|
50 |
2005-06-05 2.0a Beta: Real Plugin! Static file generation, Admin UI
|
51 |
2005-06-05 2.0 Various fixes, more help, more comments, configurable filename
|
52 |
2005-06-07 2.01 Fixed 2 Bugs: 147 is now _e(strval($i)); instead of _e($i); 344 uses a full < ?php instead of < ?
|
53 |
+
Thanks to Christian Aust for reporting this :)
|
54 |
2005-06-07 2.1 Correct usage of last modification date for cats and archives (thx to Rodney Shupe (http://www.shupe.ca/))
|
55 |
+
Added support for .gz generation
|
56 |
+
Fixed bug which ignored different post/page priorities
|
57 |
+
Should support now different wordpress/admin directories
|
58 |
2005-06-07 2.11 Fixed bug with hardcoded table table names instead of the $wpd vars
|
59 |
2005-06-07 2.12 Changed SQL Statement of the categories to get it work on MySQL 3
|
60 |
2005-06-08 2.2 Added language file support:
|
61 |
+
- Japanese Language Files and code modifications by hiromasa (http://hiromasa.zone.ne.jp/)
|
62 |
+
- German Language File by Arne Brachhold (http://www.arnebrachhold.de)
|
63 |
+
2005-06-14 2.5 Added support for external pages
|
64 |
Added support for Google Ping
|
65 |
Added the minimum Post Priority option
|
66 |
Added Spanish Language File by César Gómez Martín (http://www.cesargomez.org/)
|
67 |
Added Italian Language File by Stefano Aglietti (http://wordpress-it.it/)
|
68 |
Added Traditional Chine Language File by Kirin Lin (http://kirin-lin.idv.tw/)
|
69 |
+
2005-07-03 2.6 Added support to store the files at a custom location
|
70 |
Changed the home URL to have a slash at the end
|
71 |
Required admin-functions.php so the script will work with external calls, wp-mail for example
|
72 |
Added support for other plugins to add content to the sitemap via add_filter()
|
73 |
+
2005-07-20 2.7 Fixed wrong date format in additional pages
|
74 |
Added Simplified Chinese Language Files by june6 (http://www.june6.cn/)
|
75 |
Added Swedish Language File by Tobias Bergius (http://tobiasbergius.se/)
|
76 |
+
2006-01-07 3.0b Added different priority calculation modes and introduced an API to create custom ones
|
77 |
Added support to use the Popularity Contest plugin by Alex King to calculate post priority
|
78 |
Added Button to restore default configuration
|
79 |
Added several links to homepage and support
|
84 |
Improved speed and optimized settings handling
|
85 |
Improved user-interface
|
86 |
Recoded plugin architecture which is now fully OOP
|
87 |
+
2006-01-07 3.0b1 Changed the way for hook support to be PHP5 and PHP4 compatible
|
88 |
Readded support for tools like w.Bloggar
|
89 |
Fixed "doubled-content" bug with WP2
|
90 |
Added xmlns to enable validation
|
91 |
+
2006-03-01 3.0b3 More performance
|
92 |
More caching
|
93 |
Better support for Popularity Contest and WP 2.x
|
94 |
+
2006-11-16 3.0b4 Fixed bug with option SELECTS
|
95 |
Decreased memory usage which should solve timeout and memory problems
|
96 |
Updated namespace to support YAHOO and MSN
|
97 |
+
2007-01-19 3.0b5 Javascripted page editor
|
98 |
WP 2 Design
|
99 |
YAHOO notification
|
100 |
New status report, removed ugly logfiles
|
108 |
- Glenn Nicholas (http://publicityship.com.au)
|
109 |
Improved file handling, thanks to VJTD3 (http://www.VJTD3.com)
|
110 |
WP 2.1 improvements
|
111 |
+
2007-01-23 3.0b6 Use memory_get_peak_usage instead of memory_get_usage if available
|
112 |
Removed the usage of REQUEST_URI since it not correct in all environments
|
113 |
Fixed that sitemap.xml.gz was not compressed
|
114 |
Added compat function "stripos" for PHP4 (Thanks to Joseph Abboud!)
|
115 |
Streamlined some code
|
116 |
+
2007-05-17 3.0b7 Added option to include the author pages like /author/john
|
117 |
Small enhancements, removed stripos dependency and the added compat function
|
118 |
Added check to not build the sitemap if importing posts
|
119 |
Fixed missing domain parameter for translator name
|
121 |
Fixed wrong XSLT location (Thanks froosh)
|
122 |
Added Ask.com notification
|
123 |
Removed unused javascript
|
124 |
+
2007-07-22 3.0b8 Changed category SQL to prevent unused cats from beeing included
|
125 |
Plugin will be loaded on "init" instead of direclty after the file has been loaded.
|
126 |
Added support for robots.txt modification
|
127 |
Switched YAHOO ping API from YAHOO Web Services to the "normal" ping service which doesn't require an app id
|
128 |
Search engines will only be pinged if the sitemap file has changed
|
129 |
+
2007-09-02 3.0b9 Added tag support for WordPress 2.3
|
130 |
Now using post_date_gmt instead of post_date everywhere
|
131 |
Fixed archive bug with static pages (Thanks to Peter Claus Lamprecht)
|
132 |
Fixed some missing translation domains, thanks to Kirin Lin!
|
133 |
Added Czech translation files for 2.7.1, thanks to Peter Kahoun (http://kahi.cz)
|
134 |
+
2007-09-04 3.0b10 Added category support for WordPress 2.3
|
135 |
Fixed bug with empty URLs in sitemap
|
136 |
Repaired GET building
|
137 |
Added more info on debug mode
|
138 |
+
2007-09-23 3.0b11 Changed mysql queries to unbuffered queries
|
139 |
Uses MUCH less memory
|
140 |
Fixed really stupid bug with search engine pings
|
141 |
Option to set how many posts will be included
|
142 |
+
2007-09-24 3.0 Yeah, 3.0 Final after one and a half year ;)
|
143 |
Removed useless functions
|
144 |
+
2007-11-03 3.0.1 Using the Snoopy HTTP client for ping requests instead of wp_remote_fopen
|
145 |
Fixed undefined translation strings
|
146 |
Added "safemode" for SQL which doesn't use unbuffered results (old style)
|
147 |
Added option to run the building process in background using wp-cron
|
148 |
Removed unnecessary function_exists, Thanks to user00265
|
149 |
Added links to test the ping if it failed.
|
150 |
+
2007-11-25 3.0.2 Fixed bug which caused that some settings were not saved correctly
|
151 |
Added option to exclude pages or post by ID
|
152 |
Restored YAHOO ping service with API key since the other one is to unreliable. (see 3.0b8)
|
153 |
2007-11-28 3.0.2.1 Fixed wrong XML Schema Location (Thanks to Emanuele Tessore)
|
154 |
Added Russian Language files by Sergey http://ryvkin.ru
|
155 |
+
2007-12-30 3.0.3 Added Live Search Ping
|
156 |
Removed some hooks which rebuilt the sitemap with every comment
|
157 |
2008-03-30 3.0.3.1 Added compatibility CSS for WP 2.5
|
158 |
2008-04-28 3.0.3.2 Improved WP 2.5 handling
|
169 |
Fixed background building bug in WP 2.1
|
170 |
Removed auto-update plugin link for WP < 2.5
|
171 |
2008-05-22 3.1 Marked as 3.1 stable, updated documentation
|
172 |
+
2008-05-27 3.1.0.1 Extracted UI JS to external file
|
173 |
Enabled the option to include following pages of multi-page posts
|
174 |
Script tries to raise memory and time limit if active
|
175 |
2008-12-21 3.1.1 Fixed redirect issue if wp-admin is rewritten via mod_rewrite, thanks to macjoost
|
301 |
Don't gzip if behind Varnish
|
302 |
Improved compatibility with caches
|
303 |
Ping on post edit
|
304 |
+
2014-06-23 4.0.7 Better compatibility with managed GoDaddy hosting (clear alloptions cache when generating the sitemap)
|
305 |
+
Improved checking if the sitemap should be gzipped or not (depending on ob levels)
|
306 |
+
Removed WordPress version from the sitemap
|
307 |
+
Corrected link to WordPress privacy settings
|
308 |
+
Changed hook which is being used for sitemap pings
|
309 |
+
|
310 |
|
311 |
Todo:
|
312 |
==============================================================================
|
351 |
$generatorObject = &GoogleSitemapGenerator::GetInstance();
|
352 |
if($generatorObject!=null) $generatorObject->AddUrl("http://blog.uri/tags/hello/",time(),"daily",0.5);
|
353 |
}
|
354 |
+
add_action("sm_buildmap", "your_pages");
|
355 |
|
356 |
Parameters:
|
357 |
- The URL to the page
|
readme.txt
CHANGED
@@ -4,7 +4,9 @@ Donate link: http://www.arnebrachhold.de/redir/sitemap-paypal
|
|
4 |
Tags: seo, google, sitemaps, google sitemaps, yahoo, msn, ask, live, xml sitemap, xml
|
5 |
Requires at least: 3.3
|
6 |
Tested up to: 3.9
|
7 |
-
Stable tag: 4.0.
|
|
|
|
|
8 |
|
9 |
This plugin will generate a special XML sitemap which will help search engines to better index your blog.
|
10 |
|
@@ -12,63 +14,75 @@ This plugin will generate a special XML sitemap which will help search engines t
|
|
12 |
|
13 |
This plugin will generate a special XML sitemap which will help search engines like Google, Bing, Yahoo and Ask.com to better index your blog. With such a sitemap, it's much easier for the crawlers to see the complete structure of your site and retrieve it more efficiently. The plugin supports all kinds of WordPress generated pages as well as custom URLs. Additionally it notifies all major search engines every time you create a post about the new content.
|
14 |
|
|
|
|
|
|
|
|
|
15 |
Related Links:
|
16 |
|
17 |
* <a href="http://www.arnebrachhold.de/projects/wordpress-plugins/google-xml-sitemaps-generator/" title="Google XML Sitemaps Plugin for WordPress">Plugin Homepage</a>
|
18 |
* <a href="http://www.arnebrachhold.de/projects/wordpress-plugins/google-xml-sitemaps-generator/changelog/" title="Changelog of the Google XML Sitemaps Plugin for WordPress">Changelog</a>
|
19 |
-
* <a href="http://www.arnebrachhold.de/
|
20 |
-
* <a href="http://wordpress.org/
|
21 |
|
22 |
== Installation ==
|
23 |
|
24 |
-
1.
|
25 |
2. Activate the plugin at the plugin administration page
|
26 |
-
3. Open the plugin configuration page, which is located under Settings -> XML-Sitemap and customize settings like priorities and change frequencies.
|
27 |
-
4. The plugin will automatically update your sitemap of you publish a post, so
|
|
|
|
|
28 |
|
29 |
-
|
|
|
|
|
30 |
|
31 |
= Do I have to create a sitemap.xml and sitemap.xml.gz by myself? =
|
32 |
|
33 |
-
|
34 |
|
35 |
-
= Does this plugin use static files
|
36 |
|
37 |
-
|
38 |
|
39 |
= There are no comments yet (or I've disabled them) and all my postings have a priority of zero! =
|
40 |
|
41 |
Please disable automatic priority calculation and define a static priority for posts.
|
42 |
|
43 |
-
= So
|
44 |
|
45 |
No, only if you want to. Default values are ok for most sites.
|
46 |
|
47 |
= Does this plugin work with all WordPress versions? =
|
48 |
|
49 |
-
This version works with WordPress
|
50 |
|
51 |
= My question isn't answered here =
|
52 |
|
53 |
-
Most of the plugin options are described at the [plugin homepage](http://www.arnebrachhold.de/projects/wordpress-plugins/google-xml-sitemaps-generator/) as well as the dedicated [Google Sitemaps FAQ](http://www.arnebrachhold.de/
|
54 |
|
55 |
= My question isn't even answered there =
|
56 |
|
57 |
-
Please post your question at the [WordPress support forum](http://wordpress.org/
|
58 |
|
59 |
= What's new in the latest version? =
|
60 |
|
61 |
-
The changelog is maintained
|
|
|
|
|
|
|
|
|
62 |
|
63 |
== Changelog ==
|
64 |
|
65 |
-
|
66 |
|
67 |
== Screenshots ==
|
68 |
|
69 |
-
1.
|
70 |
-
2.
|
71 |
-
3.
|
72 |
|
73 |
== License ==
|
74 |
|
4 |
Tags: seo, google, sitemaps, google sitemaps, yahoo, msn, ask, live, xml sitemap, xml
|
5 |
Requires at least: 3.3
|
6 |
Tested up to: 3.9
|
7 |
+
Stable tag: 4.0.6
|
8 |
+
License: GPLv2
|
9 |
+
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
11 |
This plugin will generate a special XML sitemap which will help search engines to better index your blog.
|
12 |
|
14 |
|
15 |
This plugin will generate a special XML sitemap which will help search engines like Google, Bing, Yahoo and Ask.com to better index your blog. With such a sitemap, it's much easier for the crawlers to see the complete structure of your site and retrieve it more efficiently. The plugin supports all kinds of WordPress generated pages as well as custom URLs. Additionally it notifies all major search engines every time you create a post about the new content.
|
16 |
|
17 |
+
Supported since *over 9 years* and rated as the [best WordPress plugin](http://wordpress.org/plugins/browse/top-rated/), it will do exactly what it's supposed to do - providing a complete XML sitemap for search engines. It will not break your site, slow it down or annoy you. Guaranteed!
|
18 |
+
|
19 |
+
> If you like the plugin, feel free to rate it (on the right side of this page) or [donate via PayPal](http://www.arnebrachhold.de/redir/sitemap-paypal/). I'm gladly supporting this plugin since over 9 years! Thanks a lot! :)
|
20 |
+
|
21 |
Related Links:
|
22 |
|
23 |
* <a href="http://www.arnebrachhold.de/projects/wordpress-plugins/google-xml-sitemaps-generator/" title="Google XML Sitemaps Plugin for WordPress">Plugin Homepage</a>
|
24 |
* <a href="http://www.arnebrachhold.de/projects/wordpress-plugins/google-xml-sitemaps-generator/changelog/" title="Changelog of the Google XML Sitemaps Plugin for WordPress">Changelog</a>
|
25 |
+
* <a href="http://www.arnebrachhold.de/projects/wordpress-plugins/google-xml-sitemaps-generator/help/" title="Google Sitemaps FAQ">Plugin help and sitemaps FAQ</a>
|
26 |
+
* <a href="http://wordpress.org/support/topic/read-before-opening-a-new-support-topic">Support Forum</a>
|
27 |
|
28 |
== Installation ==
|
29 |
|
30 |
+
1. Install the plugin like you always install plugins, either by uploading it via FTP or by using the "Add Plugin" function of WordPress.
|
31 |
2. Activate the plugin at the plugin administration page
|
32 |
+
3. If you want: Open the plugin configuration page, which is located under Settings -> XML-Sitemap and customize settings like priorities and change frequencies.
|
33 |
+
4. The plugin will automatically update your sitemap of you publish a post, so there is nothing more to do :)
|
34 |
+
|
35 |
+
== Frequently Asked Questions ==
|
36 |
|
37 |
+
= Where can I find the options page of the plugin? =
|
38 |
+
|
39 |
+
It is under Settings > XML Sitemap. I know nowadays many plugins add top-level menu items, but in most of the cases it is just not necessary. I've seen WP installations which looked like an Internet Explorer ten years ago with 20 toolbars installed. ;-)
|
40 |
|
41 |
= Do I have to create a sitemap.xml and sitemap.xml.gz by myself? =
|
42 |
|
43 |
+
Not anymore. Since version 4, these files are dynamically generated. *There must be no sitemap.xml or sitemap.xml.gz in your blog directory anymore!* The plugin will try to rename them to sitemap.xml.bak if they still exists.
|
44 |
|
45 |
+
= Does this plugin use static files or "I can't find the sitemap.xml file!" =
|
46 |
|
47 |
+
Not anymore. Since version 4, these files are dynamically generated just like any other WordPress content.
|
48 |
|
49 |
= There are no comments yet (or I've disabled them) and all my postings have a priority of zero! =
|
50 |
|
51 |
Please disable automatic priority calculation and define a static priority for posts.
|
52 |
|
53 |
+
= So many configuration options... Do I need to change them? =
|
54 |
|
55 |
No, only if you want to. Default values are ok for most sites.
|
56 |
|
57 |
= Does this plugin work with all WordPress versions? =
|
58 |
|
59 |
+
This version works with WordPress 3.3 and better. If you're using an older version, please check the [Google Sitemaps Plugin Homepage](http://www.arnebrachhold.de/projects/wordpress-plugins/google-xml-sitemaps-generator/ "Google (XML) Sitemap Generator Plugin Homepage") for the legacy releases. There is a working release for every WordPress version since 1.5, but you really should consider updating your WordPress installation!
|
60 |
|
61 |
= My question isn't answered here =
|
62 |
|
63 |
+
Most of the plugin options are described at the [plugin homepage](http://www.arnebrachhold.de/projects/wordpress-plugins/google-xml-sitemaps-generator/) as well as the dedicated [Google Sitemaps FAQ](http://www.arnebrachhold.de/projects/wordpress-plugins/google-xml-sitemaps-generator/help/ "List of common questions / problems regarding Google (XML) Sitemaps").
|
64 |
|
65 |
= My question isn't even answered there =
|
66 |
|
67 |
+
Please post your question at the [WordPress support forum](http://wordpress.org/support/topic/read-before-opening-a-new-support-topic) and tag your post with "google-sitemap-generator".
|
68 |
|
69 |
= What's new in the latest version? =
|
70 |
|
71 |
+
The changelog is maintained [here](http://www.arnebrachhold.de/projects/wordpress-plugins/google-xml-sitemaps-generator/changelog/ "Google (XML) Sitemap Generator Plugin Changelog")
|
72 |
+
|
73 |
+
= Why is the changelog on a separate page and not here? =
|
74 |
+
|
75 |
+
The WordPress.org repository is just another place to download this plugin. I don't want to maintain too many pages with the same content. Thank you for your understanding!
|
76 |
|
77 |
== Changelog ==
|
78 |
|
79 |
+
You can always find the changelog on [the plugin website](http://www.arnebrachhold.de/projects/wordpress-plugins/google-xml-sitemaps-generator/changelog/ "Google (XML) Sitemap Generator Plugin Changelog"), since I don't like to maintain the same content on different pages. Thank you for your understanding!
|
80 |
|
81 |
== Screenshots ==
|
82 |
|
83 |
+
1. Plugin options page
|
84 |
+
2. Sample XML sitemap (with a stylesheet for making it readable)
|
85 |
+
3. Sample XML sitemap (without stylesheet)
|
86 |
|
87 |
== License ==
|
88 |
|
screenshot-1.gif
DELETED
Binary file
|
screenshot-1.png
ADDED
Binary file
|
screenshot-2.gif
DELETED
Binary file
|
screenshot-2.png
ADDED
Binary file
|
screenshot-3.gif
DELETED
Binary file
|
screenshot-3.png
ADDED
Binary file
|
sitemap-core.php
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?php
|
2 |
/*
|
3 |
|
4 |
-
$Id: sitemap-core.php
|
5 |
|
6 |
*/
|
7 |
|
@@ -846,10 +846,6 @@ final class GoogleSitemapGenerator {
|
|
846 |
public static function GetBackLink() {
|
847 |
global $wp_version;
|
848 |
$url = admin_url("options-general.php?page=" . GoogleSitemapGeneratorLoader::GetBaseName());
|
849 |
-
|
850 |
-
//Some browser cache the page... great! So lets add some no caching params depending on the WP and plugin version
|
851 |
-
$url .= '&sm_wpv=' . $wp_version . '&sm_pv=' . GoogleSitemapGeneratorLoader::GetVersion();
|
852 |
-
|
853 |
return $url;
|
854 |
}
|
855 |
|
@@ -1209,6 +1205,11 @@ final class GoogleSitemapGenerator {
|
|
1209 |
|
1210 |
$this->InitOptions();
|
1211 |
|
|
|
|
|
|
|
|
|
|
|
1212 |
//First init default values, then overwrite it with stored values so we can add default
|
1213 |
//values with an update which get stored by the next edit.
|
1214 |
$storedOptions = get_option("sm_options");
|
@@ -1589,14 +1590,14 @@ final class GoogleSitemapGenerator {
|
|
1589 |
//filter level already, which we can't detect. Zipping then would lead to invalid content.
|
1590 |
$pack = (isset($options['zip']) ? $options['zip'] : $this->GetOption('b_autozip'));
|
1591 |
if(
|
1592 |
-
empty($_SERVER['HTTP_ACCEPT_ENCODING']) //No
|
1593 |
|| strpos($_SERVER['HTTP_ACCEPT_ENCODING'],'gzip') === false //or no gzip
|
1594 |
|| !$this->IsGzipEnabled() //No PHP gzip support
|
1595 |
|| headers_sent() //Headers already sent
|
1596 |
|| ob_get_contents() //there was already some output...
|
1597 |
|| in_array('ob_gzhandler', ob_list_handlers()) //Some other plugin (or PHP) is already gzipping
|
1598 |
-
||
|
1599 |
-
|| ob_get_level() > 1 //Another
|
1600 |
|| (isset($_SERVER['HTTP_X_VARNISH']) && is_numeric($_SERVER['HTTP_X_VARNISH'])) //Behind a Varnish proxy
|
1601 |
) $pack = false;
|
1602 |
|
@@ -1690,7 +1691,6 @@ final class GoogleSitemapGenerator {
|
|
1690 |
$this->AddElement(new GoogleSitemapGeneratorXmlEntry('<' . '?xml-stylesheet type="text/xsl" href="' . $styleSheet . '"?' . '>'));
|
1691 |
}
|
1692 |
|
1693 |
-
$this->AddElement(new GoogleSitemapGeneratorDebugEntry("generator=\"wordpress/" . get_bloginfo('version') . "\""));
|
1694 |
$this->AddElement(new GoogleSitemapGeneratorDebugEntry("sitemap-generator-url=\"http://www.arnebrachhold.de\" sitemap-generator-version=\"" . $this->GetVersion() . "\""));
|
1695 |
$this->AddElement(new GoogleSitemapGeneratorDebugEntry("generated-on=\"" . date(get_option("date_format") . " " . get_option("time_format")) . "\""));
|
1696 |
|
@@ -2215,4 +2215,37 @@ final class GoogleSitemapGenerator {
|
|
2215 |
public function IsGreaterZero($value) {
|
2216 |
return ($value > 0);
|
2217 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2218 |
}
|
1 |
<?php
|
2 |
/*
|
3 |
|
4 |
+
$Id: sitemap-core.php 935247 2014-06-19 17:13:03Z arnee $
|
5 |
|
6 |
*/
|
7 |
|
846 |
public static function GetBackLink() {
|
847 |
global $wp_version;
|
848 |
$url = admin_url("options-general.php?page=" . GoogleSitemapGeneratorLoader::GetBaseName());
|
|
|
|
|
|
|
|
|
849 |
return $url;
|
850 |
}
|
851 |
|
1205 |
|
1206 |
$this->InitOptions();
|
1207 |
|
1208 |
+
//Delete the options cache. This is unfortunately required for some hosts,
|
1209 |
+
//but it is not that bad since it will only clear the options and only if a
|
1210 |
+
//sitemap is actually served or the sitemap admin page is requested.
|
1211 |
+
wp_cache_delete('alloptions', 'options');
|
1212 |
+
|
1213 |
//First init default values, then overwrite it with stored values so we can add default
|
1214 |
//values with an update which get stored by the next edit.
|
1215 |
$storedOptions = get_option("sm_options");
|
1590 |
//filter level already, which we can't detect. Zipping then would lead to invalid content.
|
1591 |
$pack = (isset($options['zip']) ? $options['zip'] : $this->GetOption('b_autozip'));
|
1592 |
if(
|
1593 |
+
empty($_SERVER['HTTP_ACCEPT_ENCODING']) //No encoding support
|
1594 |
|| strpos($_SERVER['HTTP_ACCEPT_ENCODING'],'gzip') === false //or no gzip
|
1595 |
|| !$this->IsGzipEnabled() //No PHP gzip support
|
1596 |
|| headers_sent() //Headers already sent
|
1597 |
|| ob_get_contents() //there was already some output...
|
1598 |
|| in_array('ob_gzhandler', ob_list_handlers()) //Some other plugin (or PHP) is already gzipping
|
1599 |
+
|| $this->GetPhpIniBoolean(ini_get("zlib.output_compression")) //Zlib compression in php.ini enabled
|
1600 |
+
|| ob_get_level() > (!$this->GetPhpIniBoolean(ini_get("output_buffering"))?0:1) //Another output buffer (beside of the default one) is already active
|
1601 |
|| (isset($_SERVER['HTTP_X_VARNISH']) && is_numeric($_SERVER['HTTP_X_VARNISH'])) //Behind a Varnish proxy
|
1602 |
) $pack = false;
|
1603 |
|
1691 |
$this->AddElement(new GoogleSitemapGeneratorXmlEntry('<' . '?xml-stylesheet type="text/xsl" href="' . $styleSheet . '"?' . '>'));
|
1692 |
}
|
1693 |
|
|
|
1694 |
$this->AddElement(new GoogleSitemapGeneratorDebugEntry("sitemap-generator-url=\"http://www.arnebrachhold.de\" sitemap-generator-version=\"" . $this->GetVersion() . "\""));
|
1695 |
$this->AddElement(new GoogleSitemapGeneratorDebugEntry("generated-on=\"" . date(get_option("date_format") . " " . get_option("time_format")) . "\""));
|
1696 |
|
2215 |
public function IsGreaterZero($value) {
|
2216 |
return ($value > 0);
|
2217 |
}
|
2218 |
+
|
2219 |
+
/**
|
2220 |
+
* Converts the various possible php.ini values for true and false to boolean
|
2221 |
+
*
|
2222 |
+
* @param $value string The value from ini_get
|
2223 |
+
*
|
2224 |
+
* @return bool The converted value
|
2225 |
+
*/
|
2226 |
+
public function GetPhpIniBoolean($value) {
|
2227 |
+
if (is_string($value)) {
|
2228 |
+
switch (strtolower($value)) {
|
2229 |
+
case '+':
|
2230 |
+
case '1':
|
2231 |
+
case 'y':
|
2232 |
+
case 'on':
|
2233 |
+
case 'yes':
|
2234 |
+
case 'true':
|
2235 |
+
case 'enabled':
|
2236 |
+
return true;
|
2237 |
+
|
2238 |
+
case '-':
|
2239 |
+
case '0':
|
2240 |
+
case 'n':
|
2241 |
+
case 'no':
|
2242 |
+
case 'off':
|
2243 |
+
case 'false':
|
2244 |
+
case 'disabled':
|
2245 |
+
return false;
|
2246 |
+
}
|
2247 |
+
}
|
2248 |
+
|
2249 |
+
return (boolean) $value;
|
2250 |
+
}
|
2251 |
}
|
sitemap-loader.php
CHANGED
@@ -15,7 +15,7 @@ class GoogleSitemapGeneratorLoader {
|
|
15 |
/**
|
16 |
* @var string Version of the generator in SVN
|
17 |
*/
|
18 |
-
private static $svnVersion = '$Id: sitemap-loader.php
|
19 |
|
20 |
|
21 |
/**
|
@@ -23,9 +23,7 @@ class GoogleSitemapGeneratorLoader {
|
|
23 |
*
|
24 |
* @uses add_action Adds actions for admin menu, executing pings and handling robots.txt
|
25 |
* @uses add_filter Adds filtes for admin menu icon and contexual help
|
26 |
-
* @uses GoogleSitemapGeneratorLoader::SetupRewriteHooks() Registeres the rewrite hooks
|
27 |
* @uses GoogleSitemapGeneratorLoader::CallShowPingResult() Shows the ping result on request
|
28 |
-
* @uses GoogleSitemapGeneratorLoader::ActivateRewrite() Writes rewrite rules the first time
|
29 |
*/
|
30 |
public static function Enable() {
|
31 |
|
@@ -44,11 +42,8 @@ class GoogleSitemapGeneratorLoader {
|
|
44 |
//Listen to daily ping
|
45 |
add_action('sm_ping_daily', array(__CLASS__, 'CallSendPingDaily'), 10, 1);
|
46 |
|
47 |
-
//
|
48 |
-
add_action('
|
49 |
-
add_action('publish_page', array(__CLASS__, 'SchedulePing'), 9999, 1);
|
50 |
-
add_action('delete_post', array(__CLASS__, 'SchedulePing'), 9999, 1);
|
51 |
-
add_action('post_updated', array(__CLASS__, 'SchedulePing'), 9999, 1);
|
52 |
|
53 |
//Robots.txt request
|
54 |
add_action('do_robots', array(__CLASS__, 'CallDoRobots'), 100, 0);
|
@@ -76,7 +71,6 @@ class GoogleSitemapGeneratorLoader {
|
|
76 |
* Sets up the query vars and template redirect hooks
|
77 |
* @uses GoogleSitemapGeneratorLoader::RegisterQueryVars
|
78 |
* @uses GoogleSitemapGeneratorLoader::DoTemplateRedirect
|
79 |
-
* @uses GoogleSitemapGeneratorLoader::KillFrontpageQuery
|
80 |
* @since 4.0
|
81 |
*/
|
82 |
public static function SetupQueryVars() {
|
@@ -85,7 +79,6 @@ class GoogleSitemapGeneratorLoader {
|
|
85 |
|
86 |
add_filter('template_redirect', array(__CLASS__, 'DoTemplateRedirect'), 1, 0);
|
87 |
|
88 |
-
//add_filter('parse_request', array(__CLASS__, 'KillFrontpageQuery'), 1, 0);
|
89 |
}
|
90 |
|
91 |
/**
|
@@ -204,29 +197,6 @@ class GoogleSitemapGeneratorLoader {
|
|
204 |
}
|
205 |
}
|
206 |
|
207 |
-
public static function KillFrontpageQuery() {
|
208 |
-
//add_filter('posts_request', array('GoogleSitemapGeneratorLoader', 'KillFrontpagePosts'), 1000, 2);
|
209 |
-
}
|
210 |
-
|
211 |
-
public static function KillFrontpagePosts($sql, &$query) {
|
212 |
-
// The main query is running on the front page
|
213 |
-
// And the currently running query is that main query
|
214 |
-
if(!empty($query->query_vars["xml_sitemap"])) {
|
215 |
-
// We only want to do this once: remove the filter
|
216 |
-
remove_filter('posts_request', array('GoogleSitemapGeneratorLoader', 'KillFrontpagePosts'), 1000, 2);
|
217 |
-
// Kill the FOUND_ROWS() query too
|
218 |
-
$query->query_vars['no_found_rows'] = true;
|
219 |
-
//Workaround for preventing to fetch sticky posts
|
220 |
-
$query->is_home = false;
|
221 |
-
//Prevent sending of 404 (it would happen because we didn't find any posts). Setting is_404 to true skips that check.
|
222 |
-
$query->is_404 = true;
|
223 |
-
|
224 |
-
return "SELECT ID FROM {$GLOBALS['wpdb']->posts} WHERE 1=2"; // Kill the query doesnt work anymore. Now try to select no matching posts :(
|
225 |
-
}
|
226 |
-
return $sql;
|
227 |
-
}
|
228 |
-
|
229 |
-
|
230 |
/**
|
231 |
* Registers the plugin in the admin menu system
|
232 |
*
|
@@ -269,17 +239,15 @@ class GoogleSitemapGeneratorLoader {
|
|
269 |
}
|
270 |
|
271 |
/**
|
272 |
-
*
|
273 |
-
*
|
274 |
-
* @
|
275 |
-
*
|
276 |
-
* @param $postID
|
277 |
-
*
|
278 |
-
* @return void
|
279 |
*/
|
280 |
-
public static function
|
281 |
-
|
282 |
-
|
|
|
|
|
283 |
}
|
284 |
|
285 |
/**
|
15 |
/**
|
16 |
* @var string Version of the generator in SVN
|
17 |
*/
|
18 |
+
private static $svnVersion = '$Id: sitemap-loader.php 937300 2014-06-23 18:04:11Z arnee $';
|
19 |
|
20 |
|
21 |
/**
|
23 |
*
|
24 |
* @uses add_action Adds actions for admin menu, executing pings and handling robots.txt
|
25 |
* @uses add_filter Adds filtes for admin menu icon and contexual help
|
|
|
26 |
* @uses GoogleSitemapGeneratorLoader::CallShowPingResult() Shows the ping result on request
|
|
|
27 |
*/
|
28 |
public static function Enable() {
|
29 |
|
42 |
//Listen to daily ping
|
43 |
add_action('sm_ping_daily', array(__CLASS__, 'CallSendPingDaily'), 10, 1);
|
44 |
|
45 |
+
//Post is somehow changed (also publish to publish (=edit) is fired)
|
46 |
+
add_action('transition_post_status', array(__CLASS__, 'SchedulePingOnStatusChange'), 9999, 3);
|
|
|
|
|
|
|
47 |
|
48 |
//Robots.txt request
|
49 |
add_action('do_robots', array(__CLASS__, 'CallDoRobots'), 100, 0);
|
71 |
* Sets up the query vars and template redirect hooks
|
72 |
* @uses GoogleSitemapGeneratorLoader::RegisterQueryVars
|
73 |
* @uses GoogleSitemapGeneratorLoader::DoTemplateRedirect
|
|
|
74 |
* @since 4.0
|
75 |
*/
|
76 |
public static function SetupQueryVars() {
|
79 |
|
80 |
add_filter('template_redirect', array(__CLASS__, 'DoTemplateRedirect'), 1, 0);
|
81 |
|
|
|
82 |
}
|
83 |
|
84 |
/**
|
197 |
}
|
198 |
}
|
199 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
200 |
/**
|
201 |
* Registers the plugin in the admin menu system
|
202 |
*
|
239 |
}
|
240 |
|
241 |
/**
|
242 |
+
* @param $new_status string The new post status
|
243 |
+
* @param $old_status string The old post status
|
244 |
+
* @param $post WP_Post The post object
|
|
|
|
|
|
|
|
|
245 |
*/
|
246 |
+
public static function SchedulePingOnStatusChange($new_status, $old_status, $post ) {
|
247 |
+
if($new_status == 'publish') {
|
248 |
+
set_transient('sm_ping_post_id', $post->ID, 120);
|
249 |
+
wp_schedule_single_event(time() + 5, 'sm_ping');
|
250 |
+
}
|
251 |
}
|
252 |
|
253 |
/**
|
sitemap-ui.php
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?php
|
2 |
/*
|
3 |
|
4 |
-
$Id: sitemap-ui.php
|
5 |
|
6 |
*/
|
7 |
|
@@ -622,6 +622,14 @@ HTML;
|
|
622 |
margin: 0;
|
623 |
}
|
624 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
625 |
|
626 |
<?php if (version_compare($wp_version, "3.4", "<")): //Fix style for WP 3.4 (dirty way for now..) ?>
|
627 |
|
@@ -664,7 +672,7 @@ HTML;
|
|
664 |
<?php
|
665 |
|
666 |
if(get_option('blog_public')!=1) {
|
667 |
-
?><div class="error"><p><?php echo str_replace("%s","options-
|
668 |
}
|
669 |
|
670 |
?>
|
1 |
<?php
|
2 |
/*
|
3 |
|
4 |
+
$Id: sitemap-ui.php 935247 2014-06-19 17:13:03Z arnee $
|
5 |
|
6 |
*/
|
7 |
|
622 |
margin: 0;
|
623 |
}
|
624 |
|
625 |
+
.hndle {
|
626 |
+
cursor:auto!important;
|
627 |
+
-webkit-user-select:auto!important;
|
628 |
+
-moz-user-select:auto!important;
|
629 |
+
-ms-user-select:auto!important;
|
630 |
+
user-select:auto!important;
|
631 |
+
}
|
632 |
+
|
633 |
|
634 |
<?php if (version_compare($wp_version, "3.4", "<")): //Fix style for WP 3.4 (dirty way for now..) ?>
|
635 |
|
672 |
<?php
|
673 |
|
674 |
if(get_option('blog_public')!=1) {
|
675 |
+
?><div class="error"><p><?php echo str_replace("%s","options-reading.php#blog_public",__('Your blog is currently blocking search engines! Visit the <a href="%s">Reading Settings</a> to change this.','sitemap')); ?></p></div><?php
|
676 |
}
|
677 |
|
678 |
?>
|
sitemap.php
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?php
|
2 |
|
3 |
/*
|
4 |
-
$Id: sitemap.php
|
5 |
|
6 |
Google XML Sitemaps Generator for WordPress
|
7 |
==============================================================================
|
@@ -18,7 +18,7 @@
|
|
18 |
Plugin Name: Google XML Sitemaps
|
19 |
Plugin URI: http://www.arnebrachhold.de/redir/sitemap-home/
|
20 |
Description: This plugin will generate a special XML sitemap which will help search engines like Google, Yahoo, Bing and Ask.com to better index your blog.
|
21 |
-
Version: 4.0.
|
22 |
Author: Arne Brachhold
|
23 |
Author URI: http://www.arnebrachhold.de/
|
24 |
Text Domain: sitemap
|
@@ -45,7 +45,7 @@
|
|
45 |
|
46 |
*/
|
47 |
|
48 |
-
define("SM_SUPPORTFEED_URL","http://plugin-info.arnebrachhold.de/support/
|
49 |
|
50 |
/**
|
51 |
* Check if the requirements of the sitemap plugin are met and loads the actual loader
|
1 |
<?php
|
2 |
|
3 |
/*
|
4 |
+
$Id: sitemap.php 935230 2014-06-19 16:48:30Z arnee $
|
5 |
|
6 |
Google XML Sitemaps Generator for WordPress
|
7 |
==============================================================================
|
18 |
Plugin Name: Google XML Sitemaps
|
19 |
Plugin URI: http://www.arnebrachhold.de/redir/sitemap-home/
|
20 |
Description: This plugin will generate a special XML sitemap which will help search engines like Google, Yahoo, Bing and Ask.com to better index your blog.
|
21 |
+
Version: 4.0.7
|
22 |
Author: Arne Brachhold
|
23 |
Author URI: http://www.arnebrachhold.de/
|
24 |
Text Domain: sitemap
|
45 |
|
46 |
*/
|
47 |
|
48 |
+
define("SM_SUPPORTFEED_URL","http://plugin-info.arnebrachhold.de/support/support_3.xml");
|
49 |
|
50 |
/**
|
51 |
* Check if the requirements of the sitemap plugin are met and loads the actual loader
|