Forums

[resolved] How to make a page link in the menu to open the startpage (8 posts)

  1. Lennart Pettersson
    Member
    Posted 2 years ago #

    Im not sure but I might have deleted the Home link in the top menu, and after making a new one I dont know how to point it to the startpage. Is there anyway to do this?
    Thanks in advance

  2. jessn
    Member
    Posted 2 years ago #

    <a href="<?php echo get_settings('home'); ?>">Home</a>

  3. Lennart Pettersson
    Member
    Posted 2 years ago #

    Im a beginner at WP so Im not sure where to put that
    Thanks

  4. jessn
    Member
    Posted 2 years ago #

    Ok. Where did you make the new link to the home page in the top menu? Did you do it directly on a file, like header.php? You just have to wrap the word "Home" (or whatever your link says) with the <a href= part.

  5. Lennart Pettersson
    Member
    Posted 2 years ago #

    No I added a new page (to get the Home link in the menu)

  6. jessn
    Member
    Posted 2 years ago #

    And you want that new page to be the home page? Ok, then go to "Settings"--"Reading" and select "Front page displays a static page" and pick your new page "Home" from the drop down menu.

  7. Lennart Pettersson
    Member
    Posted 2 years ago #

    I solved it now. Thank you so much!

  8. Lennart Pettersson
    Member
    Posted 2 years ago #

    I should explain better I guess,
    I put your code in header.php in the main-nav
    It worked great.

Topic Closed

This topic has been closed to new replies.

About this Topic