Auto Nav with changing background images
Permalink
Hi,
I'm currently building a site where to keep the nav bar a bit more interesting I have four different background images that I'd like to alternate between, so for example:
- Home - Image 1
- About - Image 2
- Contact - Image 3
- Etc
I'm not sure whether or not this is possible to do but any recommendations would be appreciated. If worst comes to worst I will place a content block that I can manually add the image and link up the page.
Thanks in advance.
I'm currently building a site where to keep the nav bar a bit more interesting I have four different background images that I'd like to alternate between, so for example:
- Home - Image 1
- About - Image 2
- Contact - Image 3
- Etc
I'm not sure whether or not this is possible to do but any recommendations would be appreciated. If worst comes to worst I will place a content block that I can manually add the image and link up the page.
Thanks in advance.
I do this all the time with CSS. Just use an autonav block and setup a custom template so that each nav item has a unique class (you just need to un-comment some code in v5.6.1 for this). Then setup your style sheet so that the anchor tags have a text-indent of -999em and a background image. You will also need to set the anchor tag to display as a block and set the height and width to the height and width of your image.
Ahh, that's great thanks for the help! Shall have a look but may end up having to come back to you if that's alright?
Thanks for the quick response though, everyone's always helpful and quick to answer on these forums!
Thanks for the quick response though, everyone's always helpful and quick to answer on these forums!
Is the background you have an actual image or just a colour variation?
The background is an image. Pretty much the same image each time just a different colour