• Resolved courtelise

    (@courtelise)


    Good afternoon! I am creating my first theme in WordPress. Is there a link here that will tell me how to add links other than what is automatically generated?

    Let me explain: Under Pages, I have 6 main pages with sub pages under them. These are listed in my sidebar and were generated automatically by my creating the pages in the admin area.

    I want to have a menu in my template at the top of the page that lists the main pages. Yes, they will be listed twice on the page as a result.

    How do I manually link to those pages inside my template?

    I’m sorry if this is a beginner question and easily researched, but I get paid by the hour and while I’d love to get paid to surf the site all day, my boss would appreciate if I could find the answer a little faster! LOL! So thank you very much for any assistance.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Many theme authors use the template tag, wp_list_pages(), to list links to Pages in their theme.

    There’s also, with Version 2.7, a new wp_page_menu() that affords the opportunity to have ‘Home’ added to the list automatically.

    Thread Starter courtelise

    (@courtelise)

    Neither of those seemed to do what I wanted because I don’t want to list all links. I want to post individual links in custom places.

    I did this… Page Name and that seemed to do exactly what I wanted.

    This will work as long as the page ID doesn’t change. Any comment from the experts before I do this for the rest of my links?

    Yes <a href="?page_id=50">Page Name</a> is another method.

    Thread Starter courtelise

    (@courtelise)

    LOL I didn’t mean for that to make a link, but thank you. All I need to know is that it works and I won’t have problems with that method down the road with the page spontaneously changing ID numbers on me.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Links within my template’ is closed to new replies.