Google XML Sitemaps - Version 3.1.8

Version Description

Download this release

Release Info

Developer arnee
Plugin Icon 128x128 Google XML Sitemaps
Version 3.1.8
Comparing to
See all releases

Code changes from version 3.1.7 to 3.1.8

Files changed (5) hide show
  1. documentation.txt +6 -1
  2. readme.txt +14 -9
  3. sitemap-core.php +49 -48
  4. sitemap-ui.php +45 -25
  5. sitemap.php +2 -2
documentation.txt CHANGED
@@ -204,7 +204,6 @@
204
Moved global post definitions for other plugins
205
Added small icon for ozh admin menu
206
Added more help links in UI
207
-
208
2009-08-24 3.1.5 Added option to completely disable the last modification time
209
Fixed bug regarding the use of the HTTPS url for the XSL stylesheet if the sitemap was build via the admin panel
210
Improved handling of homepage if a single page was set for it
@@ -214,6 +213,12 @@
214
2009-08-31 3.1.6 Fixed PHP error "Only variables can be passed by reference"
215
Fixed wrong URLS of multi-page posts (Thanks artstorm!)
216
2009-10-21 3.1.7 Added support for custom taxonomies (Thanks to Lee!)
217
218
Maybe Todo:
219
==============================================================================
204
Moved global post definitions for other plugins
205
Added small icon for ozh admin menu
206
Added more help links in UI
207
2009-08-24 3.1.5 Added option to completely disable the last modification time
208
Fixed bug regarding the use of the HTTPS url for the XSL stylesheet if the sitemap was build via the admin panel
209
Improved handling of homepage if a single page was set for it
213
2009-08-31 3.1.6 Fixed PHP error "Only variables can be passed by reference"
214
Fixed wrong URLS of multi-page posts (Thanks artstorm!)
215
2009-10-21 3.1.7 Added support for custom taxonomies (Thanks to Lee!)
216
+ 2009-11-07 3.1.8 Improved custom taxonomy handling and fixed wrong last modification date
217
+ Changed readme and backlinks
218
+ Fixed fatal error in WP < 2.3
219
+ Fixed Update Notice in WP 2.8+
220
+ Added warning if blog privacy is activated
221
+ Fixed custom URLs priorities were shown as 0 instead of 1
222
223
Maybe Todo:
224
==============================================================================
readme.txt CHANGED
@@ -4,13 +4,13 @@ Donate link: http://www.arnebrachhold.de/redir/sitemap-paypal
4
Tags: google, sitemaps, google sitemaps, yahoo, msn, ask, live, xml sitemap, xml
5
Requires at least: 2.1
6
Tested up to: 2.9
7
- Stable tag: 3.1.6
8
9
- This plugin will create a Google sitemaps compliant XML-Sitemap of your WordPress blog.
10
11
== Description ==
12
13
- This plugin will create a Google sitemaps compliant XML-Sitemap of your WordPress blog. It supports all of the WordPress generated pages as well as custom ones. Everytime you edit or create a post, your sitemap is updated and all major search engines that support the sitemap protocol, like ASK.com, Google, MSN Search and YAHOO, are notified about the update.
14
15
Related Links:
16
@@ -19,6 +19,7 @@ Related Links:
19
* <a href="http://www.arnebrachhold.de/2006/04/07/google-sitemaps-faq-sitemap-issues-errors-and-problems/" title="Google Sitemaps FAQ">Plugin and sitemaps FAQ</a>
20
* <a href="http://wordpress.org/tags/google-sitemap-generator?forum_id=10">Support Forum</a>
21
22
23
== Installation ==
24
@@ -36,7 +37,7 @@ Please disable automatic priority calculation and define a static priority for p
36
37
= Do I always have to click on "Rebuild Sitemap" if I modified a post? =
38
39
- No, if you edit/publish/delete a post, your sitemap is automatcally regenerated
40
41
= So much configuration options... Do I need to change them? =
42
@@ -44,7 +45,7 @@ No, only if you want to. Default values should be ok!
44
45
= Does this plugin work with all WordPress versions? =
46
47
- This version works with WordPress 2.1 and better. If you're using an older version, plese 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
48
49
= I get an fopen and / or permission denied error or my sitemap files could not be written =
50
@@ -56,11 +57,15 @@ Most of the plugin options are described at the [plugin homepage](http://www.arn
56
57
= My question isn't even answered there =
58
59
- Please post your question at the [WordPress support forum](http://wordpress.org/tags/google-sitemap-generator?forum_id=10) and tag your post with &quot;google-sitemap-generator&quot;.
60
61
= What's new in the latest version? =
62
63
- The changelog is maintened on [here](http://www.arnebrachhold.de/projects/wordpress-plugins/google-xml-sitemaps-generator/changelog/ "Google (XML) Sitemap Generator Plugin Changelog")
64
65
== Screenshots ==
66
@@ -68,10 +73,10 @@ The changelog is maintened on [here](http://www.arnebrachhold.de/projects/wordpr
68
2. Administration interface in WordPress 2.5
69
3. Administration interface in WordPress 2.0
70
71
- == Licence ==
72
73
Good news, this plugin is free for everyone! Since it's released under the GPL, you can use it free of charge on your personal or commercial blog. But if you enjoy this plugin, you can thank me and leave a [small donation](http://www.arnebrachhold.de/redir/sitemap-paypal "Donate with PayPal") for the time I've spent writing and supporting this plugin. And I really don't want to know how many hours of my life this plugin has already eaten ;)
74
75
== Translations ==
76
77
- The plugin comes with various translations, please refer to the [WordPress Codex](http://codex.wordpress.org/Installing_WordPress_in_Your_Language "Installing WordPress in Your Language") for more information about activating the translation. If you want to help to translate the plugin to your language, please have a look at the sitemap.pot file which contains all defintions and may be used with a [gettext](http://www.gnu.org/software/gettext/) editor like [Poedit](http://www.poedit.net/) (Windows).
4
Tags: google, sitemaps, google sitemaps, yahoo, msn, ask, live, xml sitemap, xml
5
Requires at least: 2.1
6
Tested up to: 2.9
7
+ Stable tag: 3.1.7
8
9
+ This plugin will generate a special XML sitemap which will help search engines to better index your blog.
10
11
== Description ==
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
19
* <a href="http://www.arnebrachhold.de/2006/04/07/google-sitemaps-faq-sitemap-issues-errors-and-problems/" title="Google Sitemaps FAQ">Plugin and sitemaps FAQ</a>
20
* <a href="http://wordpress.org/tags/google-sitemap-generator?forum_id=10">Support Forum</a>
21
22
+ *This release is compatible with all WordPress versions since 2.1. If you are still using an older one, use <a href="http://downloads.wordpress.org/plugin/google-sitemap-generator.2.7.1.zip">version 2.7.1</a> instead.*
23
24
== Installation ==
25
37
38
= Do I always have to click on "Rebuild Sitemap" if I modified a post? =
39
40
+ No, if you edit/publish/delete a post, your sitemap is automatically regenerated
41
42
= So much configuration options... Do I need to change them? =
43
45
46
= Does this plugin work with all WordPress versions? =
47
48
+ This version works with WordPress 2.1 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
49
50
= I get an fopen and / or permission denied error or my sitemap files could not be written =
51
57
58
= My question isn't even answered there =
59
60
+ Please post your question at the [WordPress support forum](http://wordpress.org/tags/google-sitemap-generator?forum_id=10) and tag your post with "google-sitemap-generator".
61
62
= What's new in the latest version? =
63
64
+ The changelog is maintained on [here](http://www.arnebrachhold.de/projects/wordpress-plugins/google-xml-sitemaps-generator/changelog/ "Google (XML) Sitemap Generator Plugin Changelog")
65
+
66
+ == Changelog ==
67
+
68
+ Until it appears here, the changelog is maintained on [the plugin website](http://www.arnebrachhold.de/projects/wordpress-plugins/google-xml-sitemaps-generator/changelog/ "Google (XML) Sitemap Generator Plugin Changelog")
69
70
== Screenshots ==
71
73
2. Administration interface in WordPress 2.5
74
3. Administration interface in WordPress 2.0
75
76
+ == License ==
77
78
Good news, this plugin is free for everyone! Since it's released under the GPL, you can use it free of charge on your personal or commercial blog. But if you enjoy this plugin, you can thank me and leave a [small donation](http://www.arnebrachhold.de/redir/sitemap-paypal "Donate with PayPal") for the time I've spent writing and supporting this plugin. And I really don't want to know how many hours of my life this plugin has already eaten ;)
79
80
== Translations ==
81
82
+ The plugin comes with various translations, please refer to the [WordPress Codex](http://codex.wordpress.org/Installing_WordPress_in_Your_Language "Installing WordPress in Your Language") for more information about activating the translation. If you want to help to translate the plugin to your language, please have a look at the sitemap.pot file which contains all definitions and may be used with a [gettext](http://www.gnu.org/software/gettext/) editor like [Poedit](http://www.poedit.net/) (Windows).
sitemap-core.php CHANGED
@@ -1,7 +1,7 @@
1
<?php
2
/*
3
4
- $Id: sitemap-core.php 165547 2009-10-21 20:19:36Z arnee $
5
6
*/
7
@@ -863,7 +863,7 @@ class GoogleSitemapGenerator {
863
/**
864
* @var Version of the generator in SVN
865
*/
866
- var $_svnVersion = '$Id: sitemap-core.php 165547 2009-10-21 20:19:36Z arnee #x27;;
867
868
/**
869
* @var array The unserialized array with the stored options
@@ -1073,6 +1073,7 @@ class GoogleSitemapGenerator {
1073
$this->_options["sm_i_hide_donated"]=false; //And hide the thank you..
1074
$this->_options["sm_i_install_date"]=time(); //The installation date
1075
$this->_options["sm_i_hide_note"]=false; //Hide the note which appears after 30 days
1076
$this->_options["sm_i_hide_donors"]=false; //Hide the list of donations
1077
}
1078
@@ -2124,21 +2125,21 @@ class GoogleSitemapGenerator {
2124
//We retrieve only users with published and not password protected posts (and not pages)
2125
//WP2.1 introduced post_status='future', for earlier WP versions we need to check the post_date_gmt
2126
$sql = "SELECT DISTINCT
2127
- {$wpdb->users}.ID,
2128
- {$wpdb->users}.user_nicename,
2129
- MAX({$wpdb->posts}.post_modified_gmt) AS last_post
2130
FROM
2131
- {$wpdb->users},
2132
- {$wpdb->posts}
2133
WHERE
2134
- {$wpdb->posts}.post_author = {$wpdb->users}.ID
2135
- AND {$wpdb->posts}.post_status = 'publish'
2136
- AND {$wpdb->posts}.post_type = 'post'
2137
- AND {$wpdb->posts}.post_password = ''
2138
- " . (floatval($wp_version) < 2.1?"AND {$wpdb->posts}.post_date_gmt <= '" . gmdate('Y-m-d H:i:59') . "'":"") . "
2139
GROUP BY
2140
- {$wpdb->users}.ID,
2141
- {$wpdb->users}.user_nicename";
2142
2143
$authors = $wpdb->get_results($sql);
2144
@@ -2173,49 +2174,48 @@ class GoogleSitemapGenerator {
2173
if($this->GetOption("in_tax") && $this->IsTaxonomySupported()) {
2174
2175
if($debug) $this->AddElement(new GoogleSitemapGeneratorDebugEntry("Debug: Start custom taxonomies"));
2176
$enabledTaxonomies = $this->GetOption("in_tax");
2177
2178
$taxList = array();
2179
2180
foreach ($enabledTaxonomies as $taxName) {
2181
$taxonomy = get_taxonomy($taxName);
2182
- if($taxonomy) $taxList[] = $taxonomy;
2183
}
2184
2185
if(count($taxList)>0) {
2186
-
2187
- foreach ($taxList as $taxonomy) {
2188
-
2189
- if($debug) $this->AddElement(new GoogleSitemapGeneratorDebugEntry("Debug: Start Taxonomy " . $taxonomy->name));
2190
-
2191
- $terms = get_terms($taxonomy->name, array("hide_empty" => true, "hierarchical" => false));
2192
-
2193
- if($terms && is_array($terms) && count($terms)>0) {
2194
- $termIDs = array();
2195
2196
- foreach($terms AS $term) $termIDs[] = $wpdb->escape($term->term_taxonomy_id);
2197
-
2198
- $lastMods = $wpdb->get_results("
2199
- SELECT
2200
- r.term_taxonomy_id AS term_id,
2201
- UNIX_TIMESTAMP(MAX(post_date_gmt)) as mod_date
2202
- FROM
2203
- {$wpdb->posts} p , {$wpdb->term_relationships} r
2204
- WHERE
2205
- p.ID = r.object_id
2206
- AND p.post_status = 'publish'
2207
- AND p.post_type = 'post'
2208
- AND p.post_password = ''
2209
- AND r.term_taxonomy_id IN ( ". implode(',',$termIDs) .")
2210
- ", OBJECT_K);
2211
-
2212
- foreach($terms AS $term) {
2213
- $lastMod = (array_key_exists($term->term_taxonomy_id,$lastMods)?$lastMods[$term->term_taxonomy_id]->mod_date:0);
2214
- $this->AddUrl(get_term_link($term,$taxonomy->name),$lastMod,$this->GetOption("cf_tags"),$this->GetOption("pr_tags"));
2215
- }
2216
- }
2217
-
2218
- if($debug) $this->AddElement(new GoogleSitemapGeneratorDebugEntry("Debug: End Taxonomy " . $taxonomy->name));
2219
}
2220
}
2221
@@ -2415,7 +2415,8 @@ class GoogleSitemapGenerator {
2415
$currentVal=(float) $currentVal;
2416
for($i=0.0; $i<=1.0; $i+=0.1) {
2417
$v = number_format($i,1,".","");
2418
- $t = number_format_i18n($i,1);
2419
echo "<option value=\"" . $v . "\" " . $this->HtmlGetSelected("$i","$currentVal") .">";
2420
echo $t;
2421
echo "</option>";
1
<?php
2
/*
3
4
+ $Id: sitemap-core.php 170451 2009-11-04 18:13:46Z arnee $
5
6
*/
7
863
/**
864
* @var Version of the generator in SVN
865
*/
866
+ var $_svnVersion = '$Id: sitemap-core.php 170451 2009-11-04 18:13:46Z arnee #x27;;
867
868
/**
869
* @var array The unserialized array with the stored options
1073
$this->_options["sm_i_hide_donated"]=false; //And hide the thank you..
1074
$this->_options["sm_i_install_date"]=time(); //The installation date
1075
$this->_options["sm_i_hide_note"]=false; //Hide the note which appears after 30 days
1076
+ $this->_options["sm_i_hide_works"]=false; //Hide the "works?" message which appears after 15 days
1077
$this->_options["sm_i_hide_donors"]=false; //Hide the list of donations
1078
}
1079
2125
//We retrieve only users with published and not password protected posts (and not pages)
2126
//WP2.1 introduced post_status='future', for earlier WP versions we need to check the post_date_gmt
2127
$sql = "SELECT DISTINCT
2128
+ p.ID,
2129
+ p.user_nicename,
2130
+ MAX(p.post_modified_gmt) AS last_post
2131
FROM
2132
+ {$wpdb->users} u,
2133
+ {$wpdb->posts} p
2134
WHERE
2135
+ p.post_author = u.ID
2136
+ AND p.post_status = 'publish'
2137
+ AND p.post_type = 'post'
2138
+ AND p.post_password = ''
2139
+ " . (floatval($wp_version) < 2.1?"AND p.post_date_gmt <= '" . gmdate('Y-m-d H:i:59') . "'":"") . "
2140
GROUP BY
2141
+ u.ID,
2142
+ u.user_nicename";
2143
2144
$authors = $wpdb->get_results($sql);
2145
2174
if($this->GetOption("in_tax") && $this->IsTaxonomySupported()) {
2175
2176
if($debug) $this->AddElement(new GoogleSitemapGeneratorDebugEntry("Debug: Start custom taxonomies"));
2177
+
2178
$enabledTaxonomies = $this->GetOption("in_tax");
2179
2180
$taxList = array();
2181
2182
foreach ($enabledTaxonomies as $taxName) {
2183
$taxonomy = get_taxonomy($taxName);
2184
+ if($taxonomy) $taxList[] = $wpdb->escape($taxonomy->name);
2185
}
2186
2187
if(count($taxList)>0) {
2188
+ //We're selecting all term information (t.*) plus some additional fields
2189
+ //like the last mod date and the taxonomy name, so WP doesnt need to make
2190
+ //additional queries to build the permalink structure.
2191
+ //This does NOT work for categories and tags yet, because WP uses get_category_link
2192
+ //and get_tag_link internally and that would cause one additional query per term!
2193
+ $sql="
2194
+ SELECT
2195
+ t.*,
2196
+ tt.taxonomy AS _taxonomy,
2197
+ UNIX_TIMESTAMP(MAX(post_date_gmt)) as _mod_date
2198
+ FROM
2199
+ {$wpdb->posts} p ,
2200
+ {$wpdb->term_relationships} r,
2201
+ {$wpdb->terms} t,
2202
+ {$wpdb->term_taxonomy} tt
2203
+ WHERE
2204
+ p.ID = r.object_id
2205
+ AND p.post_status = 'publish'
2206
+ AND p.post_type = 'post'
2207
+ AND p.post_password = ''
2208
+ AND r.term_taxonomy_id = t.term_id
2209
+ AND t.term_id = tt.term_id
2210
+ AND tt.count > 0
2211
+ AND tt.taxonomy IN ('" . implode("','",$taxList) . "')
2212
+ GROUP BY
2213
+ t.term_id";
2214
2215
+ $termInfo = $wpdb->get_results($sql);
2216
+
2217
+ foreach($termInfo AS $term) {
2218
+ $this->AddUrl(get_term_link($term,$term->_taxonomy),$term->_mod_date ,$this->GetOption("cf_tags"),$this->GetOption("pr_tags"));
2219
}
2220
}
2221
2415
$currentVal=(float) $currentVal;
2416
for($i=0.0; $i<=1.0; $i+=0.1) {
2417
$v = number_format($i,1,".","");
2418
+ //number_format_i18n is there since WP 2.3
2419
+ $t = function_exists('number_format_i18n')?number_format_i18n($i,1):number_format($i,1);
2420
echo "<option value=\"" . $v . "\" " . $this->HtmlGetSelected("$i","$currentVal") .">";
2421
echo $t;
2422
echo "</option>";
sitemap-ui.php CHANGED
@@ -1,7 +1,7 @@
1
<?php
2
/*
3
4
- $Id: sitemap-ui.php 165547 2009-10-21 20:19:36Z arnee $
5
6
*/
7
@@ -90,6 +90,10 @@ class GoogleSitemapGeneratorUI {
90
$this->sg->SetOption('i_hide_donors',true);
91
$this->sg->SaveOptions();
92
}
93
94
if(isset($_GET['sm_donated']) || ($this->sg->GetOption('i_donated')===true && $this->sg->GetOption('i_hide_donated')!==true)) {
95
?>
@@ -100,7 +104,14 @@ class GoogleSitemapGeneratorUI {
100
} else if($this->sg->GetOption('i_donated') !== true && $this->sg->GetOption('i_install_date')>0 && $this->sg->GetOption('i_hide_note')!==true && time() > ($this->sg->GetOption('i_install_date') + (60*60*24*30))) {
101
?>
102
<div class="updated">
103
- <strong><p><?php echo str_replace("%s",$this->sg->GetRedirectLink("sitemap-donate-note"),__('Thanks for using this plugin! You\'ve installed this plugin over a month ago. If it works and your are satisfied with the results, isn\'t it worth at least one dollar? <a href="%s">Donations</a> help me to continue support and development of this <i>free</i> software! <a href="%s">Sure, no problem!</a>','sitemap')); ?> <a href="<?php echo $this->sg->GetBackLink() . "&amp;sm_hide_note=true"; ?>" style="float:right; display:block; border:none;"><small style="font-weight:normal; "><?php _e('No thanks, please don\'t bug me anymore!', 'sitemap'); ?></small></a></p></strong>
104
<div style="clear:right;"></div>
105
</div>
106
<?php
@@ -458,29 +469,38 @@ class GoogleSitemapGeneratorUI {
458
<div class="wrap" id="sm_div">
459
<form method="post" action="<?php echo $this->sg->GetBackLink() ?>">
460
<h2><?php _e('XML Sitemap Generator for WordPress', 'sitemap'); echo " " . $this->sg->GetVersion() ?> </h2>
461
- <?php
462
- if(function_exists("wp_update_plugins") && (!defined('SM_NO_UPDATE') || SM_NO_UPDATE == false)) {
463
- wp_update_plugins();
464
-
465
- $file = GoogleSitemapGeneratorLoader::GetBaseName();
466
-
467
- $plugin_data = get_plugin_data(GoogleSitemapGeneratorLoader::GetPluginFile());
468
- $current = get_option( 'update_plugins' );
469
- if(isset($current->response[$file])) {
470
- $r = $current->response[$file];
471
- ?><div id="update-nag" class="sm-update-nag"><?php
472
- if ( !current_user_can('edit_plugins') || version_compare($wp_version,"2.5","<") )
473
- printf( __('There is a new version of %1$s available. <a href="%2$s">Download version %3$s here</a>.','default'), $plugin_data['Name'], $r->url, $r->new_version);
474
- else if ( empty($r->package) )
475
- printf( __('There is a new version of %1$s available. <a href="%2$s">Download version %3$s here</a> <em>automatic upgrade unavailable for this plugin</em>.','default'), $plugin_data['Name'], $r->url, $r->new_version);
476
- else
477
- printf( __('There is a new version of %1$s available. <a href="%2$s">Download version %3$s here</a> or <a href="%4$s">upgrade automatically</a>.','default'), $plugin_data['Name'], $r->url, $r->new_version, wp_nonce_url("update.php?action=upgrade-plugin&amp;plugin=$file", 'upgrade-plugin_' . $file) );
478
-
479
- ?></div><?php
480
- }
481
- }
482
- ?>
483
484
<?php if(version_compare($wp_version,"2.5","<")): ?>
485
<script type="text/javascript" src="../wp-includes/js/dbx.js"></script>
486
<script type="text/javascript">
@@ -863,7 +883,7 @@ class GoogleSitemapGeneratorUI {
863
for($i=0; $i<count($this->sg->_pages); $i++) {
864
$v=&$this->sg->_pages[$i];
865
if($i>0) echo ",";
866
- echo '{url:"' . $v->getUrl() . '", priority:"' . number_format($v->getPriority(),1,".","") . '", changeFreq:"' . $v->getChangeFreq() . '", lastChanged:"' . ($v!=null && $v->getLastMod()>0?date("Y-m-d",$v->getLastMod()):"") . '"}';
867
}
868
}
869
?> ];
1
<?php
2
/*
3
4
+ $Id: sitemap-ui.php 166557 2009-10-24 15:48:23Z arnee $
5
6
*/
7
90
$this->sg->SetOption('i_hide_donors',true);
91
$this->sg->SaveOptions();
92
}
93
+ if(isset($_GET['sm_hide_works'])) {
94
+ $this->sg->SetOption('i_hide_works',true);
95
+ $this->sg->SaveOptions();
96
+ }
97
98
if(isset($_GET['sm_donated']) || ($this->sg->GetOption('i_donated')===true && $this->sg->GetOption('i_hide_donated')!==true)) {
99
?>
104
} else if($this->sg->GetOption('i_donated') !== true && $this->sg->GetOption('i_install_date')>0 && $this->sg->GetOption('i_hide_note')!==true && time() > ($this->sg->GetOption('i_install_date') + (60*60*24*30))) {
105
?>
106
<div class="updated">
107
+ <strong><p><?php echo str_replace("%s",$this->sg->GetRedirectLink("sitemap-donate-note"),__('Thanks for using this plugin! You\'ve installed this plugin over a month ago. If it works and your are satisfied with the results, isn\'t it worth at least one dollar? <a href="%s">Donations</a> help me to continue support and development of this <i>free</i> software! <a href="%s">Sure, no problem!</a>','sitemap')); ?> <a href="<?php echo $this->sg->GetBackLink() . "&amp;sm_donated=true"; ?>" style="float:right; display:block; border:none; margin-left:10px;"><small style="font-weight:normal; "><?php _e('Sure, but I already did!', 'sitemap'); ?></small></a> <a href="<?php echo $this->sg->GetBackLink() . "&amp;sm_hide_note=true"; ?>" style="float:right; display:block; border:none;"><small style="font-weight:normal; "><?php _e('No thanks, please don\'t bug me anymore!', 'sitemap'); ?></small></a></p></strong>
108
+ <div style="clear:right;"></div>
109
+ </div>
110
+ <?php
111
+ } else if($this->sg->GetOption('i_install_date')>0 && $this->sg->GetOption('i_hide_works')!==true && time() > ($this->sg->GetOption('i_install_date') + (60*60*24*15))) {
112
+ ?>
113
+ <div class="updated">
114
+ <strong><p><?php echo str_replace("%s",$this->sg->GetRedirectLink("sitemap-works-note"),__('Thanks for using this plugin! You\'ve installed this plugin some time ago. If it works and your are satisfied, why not <a href="%s">rate it</a> and <a href="%s">recommend it</a> to others? :-)','sitemap')); ?> <a href="<?php echo $this->sg->GetBackLink() . "&amp;sm_hide_works=true"; ?>" style="float:right; display:block; border:none;"><small style="font-weight:normal; "><?php _e('Don\'t show this anymore', 'sitemap'); ?></small></a></p></strong>
115
<div style="clear:right;"></div>
116
</div>
117
<?php
469
<div class="wrap" id="sm_div">
470
<form method="post" action="<?php echo $this->sg->GetBackLink() ?>">
471
<h2><?php _e('XML Sitemap Generator for WordPress', 'sitemap'); echo " " . $this->sg->GetVersion() ?> </h2>
472
+ <?php
473
+ if(function_exists("wp_update_plugins") && (!defined('SM_NO_UPDATE') || SM_NO_UPDATE == false)) {
474
+
475
+ wp_update_plugins();
476
+
477
+ $file = GoogleSitemapGeneratorLoader::GetBaseName();
478
+
479
+ $plugin_data = get_plugin_data(GoogleSitemapGeneratorLoader::GetPluginFile());
480
+
481
+ $current = function_exists('get_transient')?get_transient('update_plugins'):get_option('update_plugins');
482
+
483
+ if(isset($current->response[$file])) {
484
+ $r = $current->response[$file];
485
+ ?><div id="update-nag" class="sm-update-nag"><?php
486
+ if ( !current_user_can('edit_plugins') || version_compare($wp_version,"2.5","<") )
487
+ printf( __('There is a new version of %1$s available. <a href="%2$s">Download version %3$s here</a>.','default'), $plugin_data['Name'], $r->url, $r->new_version);
488
+ else if ( empty($r->package) )
489
+ printf( __('There is a new version of %1$s available. <a href="%2$s">Download version %3$s here</a> <em>automatic upgrade unavailable for this plugin</em>.','default'), $plugin_data['Name'], $r->url, $r->new_version);
490
+ else
491
+ printf( __('There is a new version of %1$s available. <a href="%2$s">Download version %3$s here</a> or <a href="%4$s">upgrade automatically</a>.','default'), $plugin_data['Name'], $r->url, $r->new_version, wp_nonce_url("update.php?action=upgrade-plugin&amp;plugin=$file", 'upgrade-plugin_' . $file) );
492
+
493
+ ?></div><?php
494
+ }
495
+ }
496
497
+
498
+ if(get_option('blog_public')!=1) {
499
+ ?><div class="error"><p><?php echo str_replace("%s","options-privacy.php",__('Your blog is currently blocking search engines! Visit the <a href="%s">privacy settings</a> to change this.','sitemap')); ?></p></div><?php
500
+ }
501
+
502
+ ?>
503
+
504
<?php if(version_compare($wp_version,"2.5","<")): ?>
505
<script type="text/javascript" src="../wp-includes/js/dbx.js"></script>
506
<script type="text/javascript">
883
for($i=0; $i<count($this->sg->_pages); $i++) {
884
$v=&$this->sg->_pages[$i];
885
if($i>0) echo ",";
886
+ echo '{url:"' . $v->getUrl() . '", priority:' . number_format($v->getPriority(),1,".","") . ', changeFreq:"' . $v->getChangeFreq() . '", lastChanged:"' . ($v!=null && $v->getLastMod()>0?date("Y-m-d",$v->getLastMod()):"") . '"}';
887
}
888
}
889
?> ];
sitemap.php CHANGED
@@ -1,7 +1,7 @@
1
<?php
2
3
/*
4
- $Id: sitemap.php 165547 2009-10-21 20:19:36Z arnee $
5
6
Google XML Sitemaps Generator for WordPress
7
==============================================================================
@@ -25,7 +25,7 @@
25
Plugin Name: Google XML Sitemaps
26
Plugin URI: http://www.arnebrachhold.de/redir/sitemap-home/
27
Description: This plugin will generate a sitemaps.org compatible sitemap of your WordPress blog which is supported by Ask.com, Google, MSN Search and YAHOO. <a href="options-general.php?page=sitemap.php">Configuration Page</a>
28
- Version: 3.1.7
29
Author: Arne Brachhold
30
Author URI: http://www.arnebrachhold.de/
31
*/
1
<?php
2
3
/*
4
+ $Id: sitemap.php 171258 2009-11-07 18:53:24Z arnee $
5
6
Google XML Sitemaps Generator for WordPress
7
==============================================================================
25
Plugin Name: Google XML Sitemaps
26
Plugin URI: http://www.arnebrachhold.de/redir/sitemap-home/
27
Description: This plugin will generate a sitemaps.org compatible sitemap of your WordPress blog which is supported by Ask.com, Google, MSN Search and YAHOO. <a href="options-general.php?page=sitemap.php">Configuration Page</a>
28
+ Version: 3.1.8
29
Author: Arne Brachhold
30
Author URI: http://www.arnebrachhold.de/
31
*/