Links Update on Plain Vanilla
I couldn’t sleep over it, since so many of you asked how to get your links working if you have more than one category. So, here’s the code. Replace the old code from sidebar.php with this:
<!-- 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><?php echo $link_cat->cat_name; ?></h3> <ul> <?php wp_get_links($link_cat->cat_id); ?> </ul> <?php } ?> <!-- end links -->
Still better, download the theme again, if you like.

It would be nice if you can add those extra templates like about, links, archives, and contact form. A complete theme set a la kubrick would be great. Maybe in a Plain Vanilla version 2.0, we might get to see it
Mar 30, 05 at 14:02That should be standard on every Theme
J/K but that would be pretty decent, the whole overview or abridgement or compendium (Übersicht in german) would be better. Makes the editing easier.
Mar 30, 05 at 18:43I am going to adapt your vanilla (very nice) theme to use it on a book website I am going to be working on. The extra templates that Jax refers to would be nice to have.
I will probably add shades to top and bottom, just like my website has, and an elegant error detection on the comments submission (empty fields and what not).
Thanks for such wornderful theme and… think about the extra templates inclussion
Mar 30, 05 at 23:01Jax, Peti: All in good time, guys =)
David: coming from you is a huge compliment. Thanks! Yes, I’ll eventually make this a sort of complete theme, it’s just that it’s not happening immediately because of too little time I have for this.
Mar 31, 05 at 14:22Me again. Was wondering why you call the “sidebar.php” from the footer instead of the index?
Mar 16, 06 at 13:45The thing is, what I want for my page is only the other pages in sidebar and nothing more. I don’t want the links and blog sections in the sidebar and trying to figure that out right now. Any tips? When I tried to create a new one, and call the new sidebar (named as pagesidebar) with the calls commented out that I don’t want…it returned an error and said call toundefined function–so not sure what that’s about. Maybe I have to use an includes function instead?
Mar 16, 06 at 13:47I’m using your theme on my site. Thank you, by the way! Also, the links issue I had noticed, it doesn’t give the proper category of links heading.
So I tried pasting this new code into that and it gets an “unexpected T_string” error. So for now, I’ll have to leave it as is. Any idea what that’s about?
Also, you didn’t include a page.php template. Although I can build one myself, it’s a nice default to work with.
Many thanks for this great theme!
Mar 16, 06 at 21:55Ok, good stuff, I see that it’s just to replace the part with the necessary php code to alter the titles.
Mar 16, 06 at 22:23Great! Fixed…thanks.
Blastkist: For page.php, just make a copy of index.php and remove the comment related code from the file.
Mar 16, 06 at 22:28Commenting php calls should have not only the html comment like <!– –> but within the function using double slashes. See below:
<!– <?php // somefunction (); –>
Mar 17, 06 at 08:14