Version Description
Download this release
Release Info
| Developer | uberdose |
| Plugin | |
| Version | 1.4.2 |
| Comparing to | |
| See all releases | |
Code changes from version 1.4.1 to 1.4.2
- all_in_one_seo_pack.php +17 -10
- all_in_one_seo_pack.pot +3 -0
all_in_one_seo_pack.php
CHANGED
|
@@ -4,7 +4,7 @@
|
|
| 4 |
Plugin Name: All in One SEO Pack
|
| 5 |
Plugin URI: http://wp.uberdose.com/2007/03/24/all-in-one-seo-pack/
|
| 6 |
Description: Out-of-the-box SEO for your Wordpress blog.
|
| 7 |
-
Version: 1.4.
|
| 8 |
Author: uberdose
|
| 9 |
Author URI: http://wp.uberdose.com/
|
| 10 |
*/
|
|
@@ -28,7 +28,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
| 28 |
|
| 29 |
class All_in_One_SEO_Pack {
|
| 30 |
|
| 31 |
-
var $version = "1.4.
|
| 32 |
|
| 33 |
/** Max numbers of chars in auto-generated description */
|
| 34 |
var $maximum_description_length = 160;
|
|
@@ -123,7 +123,7 @@ class All_in_One_SEO_Pack {
|
|
| 123 |
if (is_feed()) {
|
| 124 |
return;
|
| 125 |
}
|
| 126 |
-
|
| 127 |
global $wp_query;
|
| 128 |
$post = $wp_query->get_queried_object();
|
| 129 |
$meta_string = null;
|
|
@@ -161,7 +161,7 @@ class All_in_One_SEO_Pack {
|
|
| 161 |
echo "ob_start_detected ";
|
| 162 |
}
|
| 163 |
echo "[$this->title_start,$this->title_end,$this->orig_title] ";
|
| 164 |
-
echo "
|
| 165 |
|
| 166 |
if ((is_home() && !$this->is_static_posts_page() && get_option('aiosp_home_keywords')) || $this->is_static_front_page()) {
|
| 167 |
$keywords = trim($this->internationalize(get_option('aiosp_home_keywords')));
|
|
@@ -184,7 +184,7 @@ class All_in_One_SEO_Pack {
|
|
| 184 |
$description = $this->internationalize(category_description());
|
| 185 |
}
|
| 186 |
|
| 187 |
-
if (isset($description) && strlen($description) > $this->minimum_description_length) {
|
| 188 |
$description = trim(strip_tags($description));
|
| 189 |
$description = str_replace('"', '', $description);
|
| 190 |
|
|
@@ -209,11 +209,11 @@ class All_in_One_SEO_Pack {
|
|
| 209 |
$description = str_replace('%blog_title%', get_bloginfo('name'), $description);
|
| 210 |
$description = str_replace('%blog_description%', get_bloginfo('description'), $description);
|
| 211 |
$description = str_replace('%wp_title%', $this->get_original_title(), $description);
|
| 212 |
-
|
| 213 |
-
|
| 214 |
}
|
| 215 |
|
| 216 |
-
if (isset ($keywords) && !empty($keywords)) {
|
| 217 |
if (isset($meta_string)) {
|
| 218 |
$meta_string .= "\n";
|
| 219 |
}
|
|
@@ -251,6 +251,8 @@ class All_in_One_SEO_Pack {
|
|
| 251 |
|
| 252 |
if ($meta_string != null) {
|
| 253 |
echo "$meta_string\n";
|
|
|
|
|
|
|
| 254 |
}
|
| 255 |
|
| 256 |
}
|
|
@@ -315,7 +317,7 @@ class All_in_One_SEO_Pack {
|
|
| 315 |
$title = null;
|
| 316 |
|
| 317 |
if (is_home()) {
|
| 318 |
-
$title =
|
| 319 |
} else if (is_single()) {
|
| 320 |
$title = $this->internationalize(wp_title('', false));
|
| 321 |
} else if (is_search() && isset($s) && !empty($s)) {
|
|
@@ -384,7 +386,12 @@ class All_in_One_SEO_Pack {
|
|
| 384 |
$title = trim($new_title);
|
| 385 |
$header = $this->replace_title($header, $title);
|
| 386 |
} else {
|
| 387 |
-
if (
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 388 |
$header = $this->replace_title($header, $this->internationalize(get_option('aiosp_home_title')));
|
| 389 |
}
|
| 390 |
}
|
| 4 |
Plugin Name: All in One SEO Pack
|
| 5 |
Plugin URI: http://wp.uberdose.com/2007/03/24/all-in-one-seo-pack/
|
| 6 |
Description: Out-of-the-box SEO for your Wordpress blog.
|
| 7 |
+
Version: 1.4.2
|
| 8 |
Author: uberdose
|
| 9 |
Author URI: http://wp.uberdose.com/
|
| 10 |
*/
|
| 28 |
|
| 29 |
class All_in_One_SEO_Pack {
|
| 30 |
|
| 31 |
+
var $version = "1.4.2";
|
| 32 |
|
| 33 |
/** Max numbers of chars in auto-generated description */
|
| 34 |
var $maximum_description_length = 160;
|
| 123 |
if (is_feed()) {
|
| 124 |
return;
|
| 125 |
}
|
| 126 |
+
|
| 127 |
global $wp_query;
|
| 128 |
$post = $wp_query->get_queried_object();
|
| 129 |
$meta_string = null;
|
| 161 |
echo "ob_start_detected ";
|
| 162 |
}
|
| 163 |
echo "[$this->title_start,$this->title_end,$this->orig_title] ";
|
| 164 |
+
echo "-->";
|
| 165 |
|
| 166 |
if ((is_home() && !$this->is_static_posts_page() && get_option('aiosp_home_keywords')) || $this->is_static_front_page()) {
|
| 167 |
$keywords = trim($this->internationalize(get_option('aiosp_home_keywords')));
|
| 184 |
$description = $this->internationalize(category_description());
|
| 185 |
}
|
| 186 |
|
| 187 |
+
if (isset($description) && (strlen($description) > $this->minimum_description_length) && !(is_home() && is_paged())) {
|
| 188 |
$description = trim(strip_tags($description));
|
| 189 |
$description = str_replace('"', '', $description);
|
| 190 |
|
| 209 |
$description = str_replace('%blog_title%', get_bloginfo('name'), $description);
|
| 210 |
$description = str_replace('%blog_description%', get_bloginfo('description'), $description);
|
| 211 |
$description = str_replace('%wp_title%', $this->get_original_title(), $description);
|
| 212 |
+
|
| 213 |
+
$meta_string .= sprintf("\n<meta name=\"description\" content=\"%s\" />", $description);
|
| 214 |
}
|
| 215 |
|
| 216 |
+
if (isset ($keywords) && !empty($keywords) && !(is_home() && is_paged())) {
|
| 217 |
if (isset($meta_string)) {
|
| 218 |
$meta_string .= "\n";
|
| 219 |
}
|
| 251 |
|
| 252 |
if ($meta_string != null) {
|
| 253 |
echo "$meta_string\n";
|
| 254 |
+
} else {
|
| 255 |
+
echo "\n";
|
| 256 |
}
|
| 257 |
|
| 258 |
}
|
| 317 |
$title = null;
|
| 318 |
|
| 319 |
if (is_home()) {
|
| 320 |
+
$title = get_option('blogname');
|
| 321 |
} else if (is_single()) {
|
| 322 |
$title = $this->internationalize(wp_title('', false));
|
| 323 |
} else if (is_search() && isset($s) && !empty($s)) {
|
| 386 |
$title = trim($new_title);
|
| 387 |
$header = $this->replace_title($header, $title);
|
| 388 |
} else {
|
| 389 |
+
if (is_paged()) {
|
| 390 |
+
global $paged;
|
| 391 |
+
$title = $this->internationalize(get_option('aiosp_home_title'));
|
| 392 |
+
$title .= " Part $paged";
|
| 393 |
+
$header = $this->replace_title($header, $title);
|
| 394 |
+
} else if ($this->internationalize(get_option('aiosp_home_title'))) {
|
| 395 |
$header = $this->replace_title($header, $this->internationalize(get_option('aiosp_home_title')));
|
| 396 |
}
|
| 397 |
}
|
all_in_one_seo_pack.pot
CHANGED
|
@@ -241,3 +241,6 @@ msgstr ""
|
|
| 241 |
msgid "Disable on this page/post:"
|
| 242 |
msgstr ""
|
| 243 |
|
|
|
|
|
|
|
|
|
| 241 |
msgid "Disable on this page/post:"
|
| 242 |
msgstr ""
|
| 243 |
|
| 244 |
+
msgid "Log important events:"
|
| 245 |
+
msgstr ""
|
| 246 |
+
|
