summaryrefslogtreecommitdiffstats
path: root/wp-includes
diff options
context:
space:
mode:
authordonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2007-01-22 11:44:06 +0000
committerdonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2007-01-22 11:44:06 +0000
commitb2f9804dae80c5f6c70c70e92a3bbde67e2615c5 (patch)
tree7615f215a90e4c797702547dab832d30887a0a54 /wp-includes
parent4e71faf4fa1a98517df1c83be342dd3714f504d2 (diff)
downloadwordpress-mu-b2f9804dae80c5f6c70c70e92a3bbde67e2615c5.tar.gz
wordpress-mu-b2f9804dae80c5f6c70c70e92a3bbde67e2615c5.tar.xz
wordpress-mu-b2f9804dae80c5f6c70c70e92a3bbde67e2615c5.zip
WP Merge to 4780
git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@854 7be80a69-a1ef-0310-a953-fb0f7c49ff36
Diffstat (limited to 'wp-includes')
-rw-r--r--wp-includes/category-template.php2
-rw-r--r--wp-includes/classes.php12
-rw-r--r--wp-includes/general-template.php4
-rw-r--r--wp-includes/post.php5
-rw-r--r--wp-includes/theme.php3
-rw-r--r--wp-includes/version.php2
6 files changed, 17 insertions, 11 deletions
diff --git a/wp-includes/category-template.php b/wp-includes/category-template.php
index b5954c5..e7eef22 100644
--- a/wp-includes/category-template.php
+++ b/wp-includes/category-template.php
@@ -237,7 +237,7 @@ function wp_list_categories($args = '') {
$output = '<li class="categories">' . $r['title_li'] . '<ul>';
if ( empty($categories) ) {
- if ( $list)
+ if ( 'list' == $style )
$output .= '<li>' . __("No categories") . '</li>';
else
$output .= __("No categories");
diff --git a/wp-includes/classes.php b/wp-includes/classes.php
index 47470d3..931eb43 100644
--- a/wp-includes/classes.php
+++ b/wp-includes/classes.php
@@ -428,14 +428,14 @@ class Walker {
if ( !empty($previous_element) && ($element->$parent_field == $previous_element->$id_field) ) {
// Previous element is my parent. Descend a level.
array_unshift($parents, $previous_element);
- $depth++; //always do this so when we start the element further down, we know where we are
if ( !$to_depth || ($depth < $to_depth) ) { //only descend if we're below $to_depth
- $cb_args = array_merge( array($output, $depth - 1), $args);
+ $cb_args = array_merge( array($output, $depth), $args);
$output = call_user_func_array(array(&$this, 'start_lvl'), $cb_args);
- } else { // If we've reached depth, end the previous element.
- $cb_args = array_merge( array($output, $previous_element, $depth - 1), $args);
+ } else if ( $to_depth && $depth == $to_depth ) { // If we've reached depth, end the previous element.
+ $cb_args = array_merge( array($output, $previous_element, $depth), $args);
$output = call_user_func_array(array(&$this, 'end_el'), $cb_args);
}
+ $depth++; //always do this so when we start the element further down, we know where we are
} else if ( $element->$parent_field == $previous_element->$parent_field) {
// On the same level as previous element.
if ( !$to_depth || ($depth <= $to_depth) ) {
@@ -452,7 +452,7 @@ class Walker {
while ( $parent = array_shift($parents) ) {
$depth--;
if ( !$to_depth || ($depth < $to_depth) ) {
- $cb_args = array_merge( array($output, $depth - 1), $args);
+ $cb_args = array_merge( array($output, $depth), $args);
$output = call_user_func_array(array(&$this, 'end_lvl'), $cb_args);
$cb_args = array_merge( array($output, $parent, $depth - 1), $args);
$output = call_user_func_array(array(&$this, 'end_el'), $cb_args);
@@ -490,7 +490,7 @@ class Walker_Page extends Walker {
function start_lvl($output, $depth) {
$indent = str_repeat("\t", $depth);
- $output .= "$indent<ul>\n";
+ $output .= "\n$indent<ul>\n";
return $output;
}
diff --git a/wp-includes/general-template.php b/wp-includes/general-template.php
index 69470db..4a5d596 100644
--- a/wp-includes/general-template.php
+++ b/wp-includes/general-template.php
@@ -919,7 +919,9 @@ function language_attributes() {
$output = "dir=\"$dir\"";
if ( $lang = get_bloginfo('language') ) {
if ( $dir ) $output .= ' ';
- $output .= "lang=\"$lang\" xml:lang=\"$lang\"";
+ if ( get_option('html_type') == 'text/html' )
+ $output .= "lang=\"$lang\"";
+ else $output .= "xml:lang=\"$lang\"";
}
echo $output;
diff --git a/wp-includes/post.php b/wp-includes/post.php
index 058db08..0fc26de 100644
--- a/wp-includes/post.php
+++ b/wp-includes/post.php
@@ -1183,10 +1183,13 @@ function generate_page_uri_index() {
$page_uris[$uri] = $id;
}
+ delete_option('page_uris');
update_option('page_uris', $page_uris);
- if ( $page_attachment_uris )
+ if ( $page_attachment_uris ) {
+ delete_option('page_attachment_uris');
update_option('page_attachment_uris', $page_attachment_uris);
+ }
}
}
diff --git a/wp-includes/theme.php b/wp-includes/theme.php
index f527b42..8c60a9c 100644
--- a/wp-includes/theme.php
+++ b/wp-includes/theme.php
@@ -399,7 +399,8 @@ function load_template($_template_file) {
global $posts, $post, $wp_did_header, $wp_did_template_redirect, $wp_query,
$wp_rewrite, $wpdb, $wp_version, $wp, $id, $comment;
- extract($wp_query->query_vars, EXTR_SKIP);
+ if ( is_array($wp_query->query_vars) )
+ extract($wp_query->query_vars, EXTR_SKIP);
require_once($_template_file);
}
diff --git a/wp-includes/version.php b/wp-includes/version.php
index 49fffa5..4813b0c 100644
--- a/wp-includes/version.php
+++ b/wp-includes/version.php
@@ -3,6 +3,6 @@
// This holds the version number in a separate file so we can bump it without cluttering the SVN
$wp_version = 'wordpress-mu-1.0'; // Let's just avoid confusion
-$wp_db_version = 3845;
+$wp_db_version = 4772;
?>