WebsiteBaker Community Forum

WebsiteBaker Support (2.8.x) => Templates, Menus & Design => Topic started by: Kwb on February 27, 2009, 12:10:01 PM

Title: Menubar image divider
Post by: Kwb on February 27, 2009, 12:10:01 PM
I'm trying to create my own template by reading the tuts here and learning some CSS. What I can't understand is: how can I use an image to divide pages shown on the horizontal menubar ( which will be the only one, for now )? I mean, how do I say to WB that it has to "spawn" this image after each page link?

Thank you and sorry if this question has been already answered and also for my English  :-P
Title: Re: Menubar image divider
Post by: BerndJM on February 27, 2009, 01:56:12 PM
Hi,

if you use show_menu2 it's easy to "style" the menu entries to fit your needs.
For example, the parameter $aItemOpen is predifined as:
Code: [Select]
'[li][a][menu_title]</a>'if you change it to:
Code: [Select]
'[li][a][menu_title]</a><img src="your_divider_image.gif" />'You have an image behind every menu-link ...

Regards Bernd
Title: Re: Menubar image divider
Post by: Kwb on February 27, 2009, 04:35:30 PM
First of all, thank you for this fast reply  :-D.
I got another question about the page links: I've understood that menu link pages must be viewed as a list, right? So for example, in HTML, with 3 pages I'll put
Code: [Select]
<ul>
<li>Page 1</li>
<li>Page 2</li>
<li>Page 3</li>
</ul>

All this 3 lines, coded in php for WB, will be:
Code: [Select]
<ul>
'[li][a][menu_title]</a><img src="your_divider_image.gif" />'
</ul>

Right?

Thanks again


Kwb
Title: Re: Menubar image divider
Post by: BerndJM on February 27, 2009, 08:17:50 PM
Hi,
it isn't a "must" to show them as a list but it's the common practice.

Your code-example is'nt right in the way you show it.
You have to use a show_men2 function-call. And set there the parameters to your needs.
Please have a look at the show_menu2 documentation (http://code.jellycan.com/files/show_menu2-README.txt), which parameters are available, what the default values are, so will get an idea what you have to do.

Regards Bernd
Title: Re: Menubar image divider
Post by: Kwb on February 28, 2009, 12:37:49 AM
Hi,
it isn't a "must" to show them as a list but it's the common practice.

Your code-example is'nt right in the way you show it.
You have to use a show_men2 function-call. And set there the parameters to your needs.
Please have a look at the show_menu2 documentation (http://code.jellycan.com/files/show_menu2-README.txt), which parameters are available, what the default values are, so will get an idea what you have to do.

Regards Bernd


Yea sorry, I knew that, I've just forgot adding the show_menu2 call...  :-P
For now I think it's everything :wink:, if I got other issues I'll ask again!
Thanks so much!

Bye   :-D


Kwb