Link Category
-
I am trying to add a new link category to my sidebar, however when i do this, the link heading is the same for all categories, ie
I want something like
Travel Links
-Link 1
-Link 2News Links
-Link 1
-Link 2However I am getting
Travel Links
-Link 1
-Link 2Travel Links
-Link 1
-Link 2The script i am using is as follows:
<!– start links –>
<?php /* If this is the frontpage */ if ( is_home() || is_page() ) { ?><?php
$link_cats = $wpdb->get_results(“SELECT cat_id, cat_name FROM $wpdb->linkcategories”);
foreach ($link_cats as $link_cat) {
?>
<h3>Travel Links</h3>-
<?php wp_get_links($link_cat->cat_id); ?>
<?php } ?>
<!– end links –>
Can someone tell me the correct script i need, btw the site is
if I havent explained it very clearly
The topic ‘Link Category’ is closed to new replies.