Make WordPress Core


Ignore:
Timestamp:
02/05/2004 08:55:50 PM (21 years ago)
Author:
rboren
Message:

Clean feed and trackback URLs.

File:
1 edited

Legend:

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

    r801 r836  
    3535    if ($echo) echo $link;
    3636    return $link;
     37}
     38
     39function get_category_rss_link($echo = false, $category_id, $category_nicename) {
     40       global $querystring_start, $querystring_equal, $siteurl;
     41       $cat_ID = $category_id;
     42       $permalink_structure = get_settings('permalink_structure');
     43
     44       if ('' == $permalink_structure) {
     45               $file = "$siteurl/wp-rss2.php";
     46        $link = $file . $querystring_start . 'cat' . $querystring_equal . $category_id;
     47       } else {
     48        $link = get_category_link(0, $category_id, $category_nicename);
     49               $link = $link . "/feed/";
     50       }
     51
     52       if ($echo) echo $link;
     53       return $link;
    3754}
    3855
Note: See TracChangeset for help on using the changeset viewer.