[wp-cvs]
wordpress/wp-includes template-functions-general.php, 1.39, 1.40
Ryan Boren
rboren at users.sourceforge.net
Wed Jul 28 03:30:18 UTC 2004
- Previous message: [wp-cvs] wordpress/wp-includes classes.php, 1.2, 1.3 functions.php,
1.134, 1.135 template-functions-comment.php, 1.26,
1.27 template-functions-general.php, 1.38, 1.39
- Next message: [wp-cvs] wordpress/wp-admin edit-form-comment.php, 1.11,
1.12 post.php, 1.70, 1.71
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /cvsroot/cafelog/wordpress/wp-includes
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22888
Modified Files:
template-functions-general.php
Log Message:
Fix wp_title() display of category_name.
Index: template-functions-general.php
===================================================================
RCS file: /cvsroot/cafelog/wordpress/wp-includes/template-functions-general.php,v
retrieving revision 1.39
retrieving revision 1.40
diff -C2 -d -r1.39 -r1.40
*** template-functions-general.php 28 Jul 2004 02:43:54 -0000 1.39
--- template-functions-general.php 28 Jul 2004 03:30:15 -0000 1.40
***************
*** 99,103 ****
function wp_title($sep = '»', $display = true) {
global $wpdb;
! global $m, $year, $monthnum, $day, $cat, $p, $name, $month, $posts;
// If there's a category
--- 99,103 ----
function wp_title($sep = '»', $display = true) {
global $wpdb;
! global $m, $year, $monthnum, $day, $cat, $category_name, $p, $name, $month, $posts;
// If there's a category
***************
*** 108,111 ****
--- 108,119 ----
}
if (!empty($category_name)) {
+ if (stristr($category_name,'/')) {
+ $category_name = explode('/',$category_name);
+ if ($category_name[count($category_name)-1]) {
+ $category_name = $category_name[count($category_name)-1]; // no trailing slash
+ } else {
+ $category_name = $category_name[count($category_name)-2]; // there was a trailling slash
+ }
+ }
$title = $wpdb->get_var("SELECT cat_name FROM $wpdb->categories WHERE category_nicename = '$category_name'");
}
- Previous message: [wp-cvs] wordpress/wp-includes classes.php, 1.2, 1.3 functions.php,
1.134, 1.135 template-functions-comment.php, 1.26,
1.27 template-functions-general.php, 1.38, 1.39
- Next message: [wp-cvs] wordpress/wp-admin edit-form-comment.php, 1.11,
1.12 post.php, 1.70, 1.71
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the cvs
mailing list