Make WordPress Core


Ignore:
Timestamp:
01/04/2010 05:23:29 PM (15 years ago)
Author:
ryan
Message:

Introduce home_url(). Props Denis-de-Bernardy, hakre. see #9008

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/category-template.php

    r12319 r12598  
    2121
    2222    if ( empty( $catlink ) ) {
    23         $file = get_option( 'home' ) . '/';
    24         $catlink = $file . '?cat=' . $category_id;
     23        $catlink = home_url('?cat=' . $category_id);
    2524    } else {
    2625        $category = &get_category( $category_id );
     
    3534
    3635        $catlink = str_replace( '%category%', $category_nicename, $catlink );
    37         $catlink = get_option( 'home' ) . user_trailingslashit( $catlink, 'category' );
     36        $catlink = home_url( user_trailingslashit( $catlink, 'category' ) );
    3837    }
    3938    return apply_filters( 'category_link', $catlink, $category_id );
Note: See TracChangeset for help on using the changeset viewer.