WordPress question - linking

Discussion in 'WordPress' started by booker, Dec 30, 2006.

  1. #1
    How do I set up a header link in WordPress (home, about, contact etc.) to go offsite (different URL)? This is my first site ever...
     
    booker, Dec 30, 2006 IP
  2. geniosity

    geniosity Peon

    Messages:
    293
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Hi,

    I'd say probably just add it to your template.
     
    geniosity, Dec 30, 2006 IP
  3. itismejoshy

    itismejoshy Peon

    Messages:
    130
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #3
    edit whatever template header you are using, wp-content/themes/**your theme**/header.php, always make a backup of this file before editing, so if you mess it up you can just restore it!
     
    itismejoshy, Dec 30, 2006 IP
  4. booker

    booker Peon

    Messages:
    5
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Thanks for the suggestions but I don't know how to do that... I looked in the header.php file but couldn't find any of the link references (home, about etc.) although they are there on the webpage. Looking at the page source the header links (href s) are under <div id="header"> Where in the template do I find the code to change?

    I've added a "page" which provides a header button that links to a WordPress page by that name. Can I just change the <a href="target"</a> to my exterior page URL? If so, where do I find "that" to change? I just want to add a header "button" to link to an external page.

    I've been looking at this for a while and it has been fun but I sure got lost in a hurry...
     
    booker, Dec 30, 2006 IP
  5. andreww

    andreww Peon

    Messages:
    169
    Likes Received:
    12
    Best Answers:
    0
    Trophy Points:
    0
    #5
    you'd prob want to add it to your sidebar template.

    you can either write the raw html there and save the file, else you can use a wysiwyg editor and cut and paste the code over.

    ps: btw u do know that a blog comprises several pieces of PHP code that are assembled to present the page, right?
    so you wouldnt find the sidebar in the header file.

    and under 'presentation' and 'theme editor' you can use the inbuilt template editor....
    it sounds like you're opening it up in some kinda text editor or something...
     
    andreww, Dec 30, 2006 IP
  6. booker

    booker Peon

    Messages:
    5
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #6
    Sidebar? I was hoping to put the link along the top. It's a WordPress triK2 theme. Would it be better/easier in the sidebar? I was using the Web Developer extension in Firefox to view the source.

    I'll take a peek at the 'presentation' and 'theme editor'.

    Thanks!
     
    booker, Dec 30, 2006 IP
  7. booker

    booker Peon

    Messages:
    5
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #7
    It would seen I don't know enough to try your suggestions. I'm sure I'm missing something, surely...

    How do I add an offsite link and button to the header on a Wordpress triK2 theme? Offsite links in blogrolls appear obvious enough but I seem to be having a tough time with header links. Any ideas where a newbie could look? TIA
     
    booker, Dec 31, 2006 IP
  8. andreww

    andreww Peon

    Messages:
    169
    Likes Received:
    12
    Best Answers:
    0
    Trophy Points:
    0
    #8
    hmm...

    like what joshy was saying: "wp-content/themes/**your theme**/header.php"

    i havent experimented with the header much myself...
     
    andreww, Jan 1, 2007 IP
  9. booker

    booker Peon

    Messages:
    5
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #9
    Okay, here's what I found out.

    Thanks itismejoshy and andreww! As you said, the change has to be made in the header.php code. What I missed was generously pointed out by one of the advisers at the WordPress "How-To and Troubleshooting" forum. I needed to find: <div id="header"> and add my link after the: <?php wp_list_pages('arguments'); ?>

    <div id="header">
    <ul>
    <?php wp_list_pages('arguments'); ?>
    <li>YOUR LINK</li>
    </ul>
    </div>

    That did the trick! and a sincere thanks to you all...
     
    booker, Jan 1, 2007 IP
  10. itismejoshy

    itismejoshy Peon

    Messages:
    130
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #10
    good luck bud, i would also suggest goin to like wordpress.org and gettin some help on the blogs there they are very helpfull! just keep trying you will get it! and MAKE BACKUPS!
     
    itismejoshy, Jan 2, 2007 IP