WebsiteBaker Logo
  • *
  • Templates
  • Help
  • Add-ons
  • Download
  • Home
*
Welcome, Guest. Please login or register.

Login with username, password and session length
 

News


WebsiteBaker 2.13.6 is now available!


Will it continue with WB? It goes on! | Geht es mit WB weiter? Es geht weiter!
https://forum.websitebaker.org/index.php/topic,32340.msg226702.html#msg226702


The forum email address board@websitebaker.org is working again
https://forum.websitebaker.org/index.php/topic,32358.0.html


R.I.P Dietmar (luisehahne) and thank you for all your valuable work for WB
https://forum.websitebaker.org/index.php/topic,32355.0.html


* Support WebsiteBaker

Your donations will help to:

  • Pay for our dedicated server
  • Pay for domain registration
  • and much more!

You can donate by clicking on the button below.


  • Home
  • Help
  • Search
  • Login
  • Register

  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.8.x) »
  • Templates, Menus & Design »
  • Menu to display as images
  • Print
Pages: [1]   Go Down

Author Topic: Menu to display as images  (Read 3686 times)

daydreamer

  • Guest
Menu to display as images
« on: March 07, 2009, 12:37:39 PM »
If my menu has, Home, About Us, Contact Us
How would I set them to display as images?
Logged

chio

  • Guest
Re: Menu to display as images
« Reply #1 on: March 07, 2009, 03:32:29 PM »
the easiest way is to hardcode them in your Template.
Logged

Offline crnogorac081

  • Posts: 2161
  • Gender: Male
Re: Menu to display as images
« Reply #2 on: March 07, 2009, 06:50:48 PM »
Hi,

This is solution for your menu which I used:

Code: [Select]
<?php show_menu(1, 0, 1, true, "[a]<img src=" .WB_URL ."/media/flags/[menu_title].gif />[/a]", &#39;&#39;, &#39;&#39;, &#39;&#39;, false, &#39;&#39;, 0); ?>

I used this to show flag images for EN and local language.

So you can use something like this:

Code: [Select]
<?php show_menu(1, 0, 1, true, "[a]<img src=" .WB_URL ."/media/menu_images/[menu_title].gif />[/a]", &#39;&#39;, &#39;&#39;, &#39;&#39;, false, &#39;&#39;, 0); ?>

As you can see, the most important part is
Code: [Select]
"[a]<img src=" .WB_URL ."/media/menu_images/[menu_title].gif />[/a]"  which calls the image, so I think that you can use
Code: [Select]
"[a]<img src=" .TEMPLATE_DIR. "/menu_images/[menu_title].gif />[/a]" and store the images in the template folder in folder menu_images and there put the images with names same as manu title...

I hope I helped you...When you finish post the link to see :))

cheers
« Last Edit: March 07, 2009, 06:53:45 PM by crnogorac081 »
Logged
Web developer

daydreamer

  • Guest
Re: Menu to display as images
« Reply #3 on: March 07, 2009, 10:21:29 PM »
Many thanks I will give this a go looks straight forward, I sure will post link when I done but a good few weeks away at the moment.

Also is there anyway to also add seprate image for hover state

Thanks Again
« Last Edit: March 07, 2009, 10:23:14 PM by daydreamer »
Logged

Offline crnogorac081

  • Posts: 2161
  • Gender: Male
Re: Menu to display as images
« Reply #4 on: March 08, 2009, 01:59:23 AM »
Unfortunatelly i did't need that, as I used images just for flags...Maybe someone else have idea for hover ??
Logged
Web developer

  • Print
Pages: [1]   Go Up
  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.8.x) »
  • Templates, Menus & Design »
  • Menu to display as images
 

  • SMF 2.0.19 | SMF © 2017, Simple Machines
  • XHTML
  • RSS
  • WAP2