Title: wp_nav_menu adding code to each ?
Last modified: August 20, 2016

---

# wp_nav_menu adding code to each ?

 *  [stephen_lsd](https://wordpress.org/support/users/stephen_lsd/)
 * (@stephen_lsd)
 * [14 years, 3 months ago](https://wordpress.org/support/topic/wp_nav_menu-adding-code-to-each/)
 * Hey all,
 * Been looking at this for a while now, and have hit a brick wall.
 * I have a static site layout created, and the navigation uses drop downs, and 
   once each link is rolled over it has a jquery rollover effect that displays an
   image on each navigation element in a particular drop down.
 * Similar to this effect – [http://cssglobe.com/lab/tooltip/03/](http://cssglobe.com/lab/tooltip/03/)
 * An example of the code form the static site is below:
 * `<li><a href="applications-snow-plough.html" class="screenshot" rel="site_images/
   pop/snowplough-pop.jpg">Snow plough</a></li>`
 * I am wondering how I would be able to make this effect apply to a wordpress version
   of the site I am working on.
 * I am using the ‘menus’ feature in the wordpress admin area, and am calling the
   navigation menu in my theme as follows.
 * `<div id="navigation"><?php wp_nav_menu( array( 'theme_location' => 'primary'));?
   ></div> <!-- #navigation -->`
 * I would like to be able to add the following to each navigation item (in a particular
   dropdown, not every link)
 * `class="screenshot" rel="site_images/pop/snowplough-pop.jpg"`
 * the next issue I have is trying to figure out how to call a featured image from
   each page that the nav points, and have appear as the pop up jquery image – I
   have a funny feeling this is going to be a nightmare to solve!

The topic ‘wp_nav_menu adding code to each ?’ is closed to new replies.

## Tags

 * [navigation](https://wordpress.org/support/topic-tag/navigation/)
 * [wp_nav_menu()](https://wordpress.org/support/topic-tag/wp_nav_menu/)

 * In: [Hacks](https://wordpress.org/support/forum/plugins-and-hacks/hacks/)
 * 0 replies
 * 1 participant
 * Last reply from: [stephen_lsd](https://wordpress.org/support/users/stephen_lsd/)
 * Last activity: [14 years, 3 months ago](https://wordpress.org/support/topic/wp_nav_menu-adding-code-to-each/)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
