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.8 is now available!


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 »
  • making different menu layout for different pages
  • Print
Pages: [1]   Go Down

Author Topic: making different menu layout for different pages  (Read 4534 times)

Availor

  • Guest
making different menu layout for different pages
« on: August 02, 2008, 02:05:47 PM »
I'm trying to play around with some ideas I have. The idea is to create different classes for different pages.
For example - first page will be blue, about pages will be green and downloads page will be yellow.

Here is my try with the code, which works partially...

Code: [Select]
<?php show_menu(1, 1, 1, true, &#39;<li>[a][menu_title][/a]</li>&#39;, &#39;&#39;, &#39;&#39;, &#39;&#39;, &#39;&#39;, &#39;
    
[if(PAGE_ID == 1) { class="active1" }]
    [elseif(
PAGE_ID == 2) { class="active2"}]
    [else { class=
"active" } ]
    
    &
#39;); ?>

I guess I'm doing something wrong there but you get the idea...
Logged

Offline Bramus

  • Posts: 608
  • Gender: Male
    • BRAMUS Internet Services
Re: making different menu layout for different pages
« Reply #1 on: August 02, 2008, 05:28:17 PM »
i think you can also do it by making different style sheets for the page_ids and then in the head section where you call the stylesheet make an if/else statement that checks for the page_id and then takes the style sheet that belongs to that page_id.

In that case you first make the site working with 1 stylesheet, then just edit the colours you want and save it on a different name like page_id2.css or contact.css or something like that.
Logged
BRAMUS Internet Services

Availor

  • Guest
Re: making different menu layout for different pages
« Reply #2 on: August 02, 2008, 07:56:00 PM »
That's also an idea... have to try that out  although it would be nice to let the user edit it from the backend
Logged

  • Print
Pages: [1]   Go Up
  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.8.x) »
  • Templates, Menus & Design »
  • making different menu layout for different pages
 

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