• I have just converted a single blog site to a multi site. The theme is shared, and the menus written in the theme header file works, except that all links on the new blog now contain a pointer to the new blog. Is there a way to have a common header menu with links that are the same for all blogs?

    I am very new to WordPress (a month) and know know nothing about php programing.

    any and all help appreciated.

Viewing 7 replies - 1 through 7 (of 7 total)
  • Yes, and we’ve posted about this before, right here in this very forum. 🙂

    hardcode it is one option.

    using the switch_to_blog function is another, but it pull the actually links from whatever blog you set (usually the main)..

    Remember, each site is a silo of its own content – you’re running your own version of wordpress.COM.

    Thread Starter Rick

    (@rick71)

    Thanks for the reply.

    I have no idea what the switch_to_blog is.

    I tried a search. Lots of them, in fact. Can you point me to some workable keywords to search, or some topic titles/ids?

    Again, thanks.

    Thread Starter Rick

    (@rick71)

    Hard coding the links seems to work. Is it possible to set a variable to an http:// path in the header and use that instead of hard coding the path in every link I need to go to the main site?

    <?php echo network_home_url(); ?>

    I have no idea what the switch_to_blog is.

    I tried a search. Lots of them, in fact. Can you point me to some workable keywords to search, or some topic titles/ids?

    Dammit. Now I’m positive the search here is broken.

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    🏳️‍🌈 Advisor and Activist

    Thread Starter Rick

    (@rick71)

    <?php echo network_home_url(); ?>

    Seems to work after some very cursory testing.

    Thank you very much.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Common header menu links’ is closed to new replies.