• Am I the only one that has this problem: themes that have a ‘Home’ link hard coded in the top navigation?

    The name ‘Home’ is normally hard coded
    And there is logic normally to test if the current page is home page or something

    Problem: when you create a page and want to make that page be home

    Typically, I will now have 2 links the both point to the home page

    This must be wrong – either I’m getting it all wrong – or everyone else coding is getting it wrong: erm… which one is right? ??

    Normally: I have to go into the header and just remove the link for the home page that is hard coded – this normally does the trick

    Is this the ONLY way? How do people who have no programming experience do it?

    Thanks!

    Omar

Viewing 3 replies - 1 through 3 (of 3 total)
  • You can exclude the second home page link from showing up. Like:

    <?php wp_list_pages(‘exclude=17,38’ ); ?>

    where 17 and 38 are the IDs of pages that you do not want to show up in the menu.

    Thread Starter OM2

    (@om2)

    thanks for that – that was useful, i didn’t know i could do that

    my question was more generic though: doesn’t everyone who installs a custom theme have this same problem as described about the home page?

    i’ve had the same problem many times – and each time, i have to delve into the code and take out bits that are causing the problem

    i shouldn’t have to do that – others won’t be able to do that because they don’t know basic programming

    + hard coding this i think is wrong

    let me know what u think

    In most cases, I don’t think any link that is capable of being generated by WordPress should be hard-coded into a theme that is meant to be publicly available. However, I guess when you are giving away something for free it is implied and sometimes even expressed that you are receiving it “as is” without any warranties. This is why there are far fewer themes available on wordpress.com than there are for self-hosted WordPress sites. The themes on wordpress.com have been tested for these kinds of problems.

    You should try writing your own theme. It’s not that difficult.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Trouble with themes that have a button called Home’ is closed to new replies.