foreach($post_categories as $c){
$cat = get_category( $c );
$cats[] = array( 'name' => $cat->name, 'slug' => $cat->slug );
- echo ', <a rel="category" title="View all posts in '. $cat->name . ' " href="'. $cat->slug .'">'. $cat->name .'</a>';
+ echo ', <a rel="category" title="View all posts in '. $cat->name . ' " href="'. get_category_link(get_cat_ID($cat->name)) .'">'. $cat->name .'</a>';
}
echo '.';
}
foreach($post_categories as $c){
$cat = get_category( $c );
$cats[] = array( 'name' => $cat->name, 'slug' => $cat->slug );
- echo '<a rel="category" title="View all posts in '. $cat->name . ' " href="'. get_permalink( get_option('page_for_posts' )).$cat->slug .'">'. $cat->name .'</a>, ';
+ echo '<a rel="category" title="View all posts in '. $cat->name . ' " href="'. get_category_link(get_cat_ID($cat->name)) .'">'. $cat->name .'</a>, ';
}
}
$post_tags = wp_get_post_tags( get_the_ID() );
foreach($post_tags as $t){
$tag = get_tag( $t );
$tags[] = array( 'name' => $tag->name, 'slug' => $tag->slug );
- echo '<a rel="category" title="View all posts in '. $tag->name . ' " href="'. get_permalink( get_option('page_for_posts' )).$tag->slug .'">'. $tag->name .'</a>, ';
+ echo '<a rel="category" title="View all posts in '. $tag->name . ' " href="'. get_tag_link(get_tag_ID($tag->name)) .'">'. $tag->name .'</a>, ';
}
}
echo ' on ';