diff --git a/wp-content/themes/default/header.php b/wp-content/themes/default/header.php index 5c21f94d18..43b729b497 100644 --- a/wp-content/themes/default/header.php +++ b/wp-content/themes/default/header.php @@ -38,7 +38,7 @@ if ( empty($withcomments) && !is_single() ) { diff --git a/wp-includes/author-template.php b/wp-includes/author-template.php index 056579c219..437724ced2 100644 --- a/wp-includes/author-template.php +++ b/wp-includes/author-template.php @@ -209,7 +209,7 @@ function get_author_posts_url($author_id, $author_nicename = '') { $link = $wp_rewrite->get_author_permastruct(); if ( empty($link) ) { - $file = get_option('home') . '/'; + $file = home_url() . '/'; $link = $file . '?author=' . $auth_ID; } else { if ( '' == $author_nicename ) { @@ -218,7 +218,7 @@ function get_author_posts_url($author_id, $author_nicename = '') { $author_nicename = $user->user_nicename; } $link = str_replace('%author%', $author_nicename, $link); - $link = get_option('home') . trailingslashit($link); + $link = home_url() . trailingslashit($link); } $link = apply_filters('author_link', $link, $author_id, $author_nicename); diff --git a/wp-includes/canonical.php b/wp-includes/canonical.php index 010e1c5e8b..e8d7e9e5d5 100644 --- a/wp-includes/canonical.php +++ b/wp-includes/canonical.php @@ -198,7 +198,7 @@ function redirect_canonical($requested_url=null, $do_redirect=true) { $redirect = @parse_url($redirect_url); // www.example.com vs example.com - $user_home = @parse_url(get_option('home')); + $user_home = @parse_url(home_url()); if ( !empty($user_home['host']) ) $redirect['host'] = $user_home['host']; if ( empty($user_home['path']) ) diff --git a/wp-includes/category-template.php b/wp-includes/category-template.php index 7e378b449f..b0c9f47386 100644 --- a/wp-includes/category-template.php +++ b/wp-includes/category-template.php @@ -20,8 +20,7 @@ function get_category_link( $category_id ) { $catlink = $wp_rewrite->get_category_permastruct(); if ( empty( $catlink ) ) { - $file = get_option( 'home' ) . '/'; - $catlink = $file . '?cat=' . $category_id; + $catlink = home_url('?cat=' . $category_id); } else { $category = &get_category( $category_id ); if ( is_wp_error( $category ) ) @@ -34,7 +33,7 @@ function get_category_link( $category_id ) { $category_nicename = get_category_parents( $category->parent, false, '/', true ) . $category_nicename; $catlink = str_replace( '%category%', $category_nicename, $catlink ); - $catlink = get_option( 'home' ) . user_trailingslashit( $catlink, 'category' ); + $catlink = home_url( user_trailingslashit( $catlink, 'category' ) ); } return apply_filters( 'category_link', $catlink, $category_id ); } diff --git a/wp-includes/classes.php b/wp-includes/classes.php index d290bbaa5b..62fbee2c13 100644 --- a/wp-includes/classes.php +++ b/wp-includes/classes.php @@ -159,7 +159,7 @@ class WP { $req_uri_array = explode('?', $req_uri); $req_uri = $req_uri_array[0]; $self = $_SERVER['PHP_SELF']; - $home_path = parse_url(get_option('home')); + $home_path = parse_url(home_url()); if ( isset($home_path['path']) ) $home_path = $home_path['path']; else diff --git a/wp-includes/comment-template.php b/wp-includes/comment-template.php index c4edd4887c..555e08aa10 100644 --- a/wp-includes/comment-template.php +++ b/wp-includes/comment-template.php @@ -967,7 +967,7 @@ function comments_popup_link( $zero = false, $one = false, $more = false, $css_c echo 'links WHERE link_url LIKE (%s) LIMIT 1", '%'.$domain.'%')) || $domain == $home_domain ) return true; @@ -1819,7 +1819,7 @@ function weblog_ping($server = '', $path = '') { // when set to true, this outputs debug messages by itself $client->debug = false; - $home = trailingslashit( get_option('home') ); + $home = trailingslashit( home_url() ); if ( !$client->query('weblogUpdates.extendedPing', get_option('blogname'), $home, get_bloginfo('rss2_url') ) ) // then try a normal ping $client->query('weblogUpdates.ping', get_option('blogname'), $home); } diff --git a/wp-includes/default-widgets.php b/wp-includes/default-widgets.php index e5219fecc3..b969e25239 100644 --- a/wp-includes/default-widgets.php +++ b/wp-includes/default-widgets.php @@ -447,7 +447,7 @@ class WP_Widget_Categories extends WP_Widget { var dropdown = document.getElementById("cat"); function onCatChange() { if ( dropdown.options[dropdown.selectedIndex].value > 0 ) { - location.href = "/?cat="+dropdown.options[dropdown.selectedIndex].value; + location.href = "/?cat="+dropdown.options[dropdown.selectedIndex].value; } } dropdown.onchange = onCatChange; diff --git a/wp-includes/feed-atom-comments.php b/wp-includes/feed-atom-comments.php index c4cd9751cf..2e7f4f360c 100644 --- a/wp-includes/feed-atom-comments.php +++ b/wp-includes/feed-atom-comments.php @@ -32,7 +32,7 @@ echo '' - + diff --git a/wp-includes/feed.php b/wp-includes/feed.php index fed45ae0c1..7bc0247033 100644 --- a/wp-includes/feed.php +++ b/wp-includes/feed.php @@ -475,7 +475,7 @@ function prep_atom_text_construct($data) { * @since 2.5 */ function self_link() { - $host = @parse_url(get_option('home')); + $host = @parse_url(home_url()); $host = $host['host']; echo esc_url( 'http' diff --git a/wp-includes/general-template.php b/wp-includes/general-template.php index b3c0f01175..00d8468fa7 100644 --- a/wp-includes/general-template.php +++ b/wp-includes/general-template.php @@ -121,7 +121,7 @@ function get_search_form() { return; } - $form = '