you should be able to do something like this
#ul-id li a:hover{
background-image: url('link');
}
most menu’s in wordpress have a unique id for the ul, if not find the closest div and sub that.
Thank you Joshua.
The code you provided seems like it would only allow me to create one background image for multiple links. I am looking for a unique image for each link in the navigation.
are you trying to use a completly different image for each one, like a blue circle with “home” written on it and a green square with “about us” written on it or all of them green squares just different text. If the latter is the case the css is rather easy, if the former you will need to do it with every item a different class.
I am trying to same thing as Eleanorha been trying.
Joshua.. Can you help me on this..
.sidebarmenu #menu-item-21 a {
background-image:url('images/new.jpg'); }
.sidebarmenu #menu-item-21 a:hover { background-image:url('images/new.jpg');}
.sidebarmenu #menu-item-22 a {
background-image:url('images/new.jpg'); }
.sidebarmenu #menu-item-22 a:hover { background-image:url('images/new.jpg');}
.sidebarmenu #menu-item-23 a {
background-image:url('images/new.jpg'); }
.sidebarmenu #menu-item-23 a:hover { background-image:url('images/new.jpg');}
.sidebarmenu #menu-item-24 a {
background-image:url('images/new.jpg'); }
.sidebarmenu #menu-item-24 a:hover { background-image:url('images/new.jpg');}
It not taking any images any help?
Thanks!
please post a link to your site to illustrate the problem –
(edit: just saw that you are developing locally, so there is really nothing anybody here can do)
fundamental formatting help is not within the scope of thie WordPress forum;
general troubleshooting questions:
are you sure you are targetting the right css selectors?
are the selectors specific enough for the individual menu items?
are you familiar with using Firebug or a similar browser tool?
you seem to be using the same background format for link and :hover – is that on purpose?
have you read about ‘css image sprites’?
OK… I’ve got it…
the wordpress generated nav_menu is in my case:
(check that by looking at you page and view the sourcecode)
<nav id="access" role="navigation">
<div class="menu">
<ul>
<li class="page_item page-item-37"><a href="http://2012.ficvaldivia.cl/?page_id=37">Festival</a>
<ul class='children'>...</ul>
</li>
<li class="page_item page-item-62"><a href="http://2012.ficvaldivia.cl/?page_id=62">Competencia</a>
<ul class='children'>...
css:
.page-item-37 {
background-image: url('images/festival.png');
}
...
.page-item-62 {
background-image: url('images/competencia.png');
}
remember: if an entry has directly a class assigned, it’s css is easily accesible by
.classname