• First day of testing WordPress ??

    Have setup a site at https://www.creativeyoungteam.com/ and installed the static-homepage plugin and edited home.php to give a customised homepage.

    I then modified sidebar.php to insert a direct link to the site root for the ‘Home’ link, and exclude the automatic link to the page it derives from, id #6 :

    <?php wp_list_pages('sort_column=menu_order&exclude=6&title_li=<h2>' . __('Navigate') . '</h2><a href="https://www.creativeyoungteam.com" title="Home">Home</a>'); ?>

    This has produced a couple of problems I can’t seem to fix:

    1. The homepage link is prefixed with a backslash “\” for some reason, and thus doesn’t work

    2. The homepage link sits outside of the list of the other pages, and doesn’t have the ‘>>’ prefix which the other page links do.

    If you look under ‘Navigate’ on the right at https://www.creativeyoungteam.com/ you should see what I mean…

    Any tips much appreciated, have trawled through codex.www.ads-software.com already!

    Thanks,

    James

Viewing 3 replies - 31 through 33 (of 33 total)
  • Well, first thing, you’d be best off to start a new thread. Second thing, this is maybe something to do with the plugin, so maybe you’d need to contact the plugin author.

    And a search on “headers already sent” might help.

    Hmmm, I’ve tried this ‘Simple method’ and it makes no difference. Any thought?

    Hi

    Actually I’ve worked this out. It’s because I have the widgets plugin active, this effects most things in my sidebar, but i’ve found I can achieve a home page link by adding echo "<a href='/'>Home</a>"; to the widget_pages function in widgets.php, before the wp_list_pages function is called

Viewing 3 replies - 31 through 33 (of 33 total)
  • The topic ‘Sidebar link to static homepage – problems’ is closed to new replies.