I want to create a separate page to list my links, rather than in the sidebar. Clicking on a 'links' menu item from the main page would display the links page.
I'm clear on everything except calling the links.php template. I'd need the anchor tag on the main page to contain some PHP magic that tells WP to do <?php get_links_list(); ?> using the links.php template. How do I do that?
I'm a bit confused.
Why would get_links_list() need to point to your template? It just displays (typically) external links; removing it from other templates and placing it only on your links.php should do (if I understand what you're asking...which I don't).
(if I understand what you're asking...which I don't)
Heh!
OK. I have a menu item on my main page called "Links". How do I make clicking on that item cause the links list to be displayed using the links.php template?
The most common templates have associated template tags (i.e., <?php get_header(); ?>, <?php get_footer(); ?>, <?php get_sidebar(); ?>, etc.), but I don't know how to call a "non-standard" template like links.php.
Ahh!
One (and perhaps the easiest) way to do this is to set up a new Page (Create > Pages). Call it Links, just to be clear about things. Doesn't require any content. Just existing will do.
Then, if you've created your links.php template according to the exacting specifications of WordPress, under Manage > Pages, edit the Links Page and assign your links.php template to it (look in the Page Options section for a Page Template dropdown).
Thanks very much for this, Kafkaesqui. I really appreciate the help!
Hi, just what I wanted to know, but here's an extra question - is there a way to do this from a theme, without having the blog owner do it? Thanks!
Jbbrwcky