WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Footer Menu has no Id (5 posts)

  1. Archie22is
    Member
    Posted 10 months ago #

    Hey guys,

    I am using the following scripts to generate a footer navigation:

    <?php
    	wp_nav_menu(
    		array(
    			'theme_location'  => 'nav_menu',
    			'depth' => 1,
    			'menu_id'	  => 'main-nav',
    			'menu_class'	  => 'footer-menu',
    			)
    		);
    ?>

    Everything works expect that my first footer link (which is home) has no id and thus makes it very difficult to even style in uniquely. My html code is as follows -

    <div class="footer-menu">
    	<ul>
    		<li class="current_page_item">
    			<a title="Home" href="http://excelprint/">Home</a>
    		</li>
    	<li class="page_item page-item-5">
    	<li class="page_item page-item-8">
    	<li class="page_item page-item-10">
    	<li class="page_item page-item-12">
    	</ul>
    </div>

    All the menu links are coloured differenty. The home page also need to be coloured differently. At the moment it overwrites my default header menu, is there a way around this?

  2. Peter_L
    Member
    Posted 10 months ago #

    At the moment it overwrites my default header menu, is there a way around this?

    What do you mean by this?

  3. Archie22is
    Member
    Posted 10 months ago #

    Okay, ignore that please (long day). Is there a way to get an id on to the home menu?

  4. Andrew
    Forum Moderator
    Posted 10 months ago #

  5. Archie22is
    Member
    Posted 10 months ago #

    Thanks Andrew... You're a LEGEND!
    That was really easy... :-)

Reply

You must log in to post.

About this Topic