About to quit on Toolbox and Wordpress because of the most simple things.
Im not a php ninja nor a Wordpress one. In fact im starting on both, but not being able to achieve the most simple things its really frustrating.
In functions.php
<?php
if ( function_exists( 'register_nav_menus' ) ) {
register_nav_menus(
array(
'top_menu' => 'My Custom Top Menu',
'sidebar_menu' => 'Super Sidebar Menu',
'main_menu' => 'Main Menu'
)
);
}
?>
on my header.php
` <div id="navigation">
-
<?php wp_nav_menu( array ( 'menu' => 'Top Menu') ); ?>
<div>`
and
<div id="sub-nav">
<ul>
<?php wp_nav_menu( array ( 'menu' => 'Main Menu' ) ); ?>
</ul>
</div>
The question is: How can i add an active state on a menu link?
It's a simple question, but after 2 hours googling for an answer im still out of luck.
Im using a free template and trying to convert it into wordpress for learning purposes using the Toolbox theme.
Thanks in advance.