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.9 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.11.x) »
  • General Help & Support (Moderator: Boudi) »
  • Help with menu?
  • Print
Pages: [1]   Go Down

Author Topic: Help with menu?  (Read 21366 times)

Offline rumen

  • Posts: 480
  • Gender: Male
Help with menu?
« on: June 27, 2022, 11:56:45 AM »
Please some help with menu of the template
Hi there,
I installed on  of the templates - "schoppig". When I click on any of the internal pages the "drop-down" appears  but on the first page it doesn't and it doesn't work.

The code is the standard for the template I just added $multilang and sm2_root+1 because of the language.

Code: [Select]
$mainnav = show_menu2(
$aMenu          = 1,
$aStart         = SM2_ROOT+1+$Multilang,
$aMaxLevel      = SM2_ALL,
$aOptions       = SM2_ALL|SM2_PRETTY|SM2_BUFFER,
$aItemOpen      = '<li><a href="[url]" class="[class]" target="[target]">[menu_title]</a>',
$aItemClose     = '</li>',
$aMenuOpen      = '<ul>',
$aMenuClose     = '</ul>',
$aTopItemOpen   = false,
$aTopMenuOpen   = '<ul class="chevron">'
  );
 
 
 
  $metanav = show_menu2(
$aMenu          = 2,
$aStart         = SM2_ROOT+1+$Multilang,
$aMaxLevel      = SM2_START,
$aOptions       = SM2_ALL|SM2_BUFFER,
$aItemOpen      = '<li><a href="[url]" class="[class]" target="[target]">[menu_title]</a>',
$aItemClose     = '</li>',
$aMenuOpen      = '<ul>',
$aMenuClose     = '</ul>',
$aTopItemOpen   = false,
$aTopMenuOpen   = '<ul class="chevron right">'
  );

What else need to fix it?

Thanks in advance!

Regards,

Rumen
Logged

Offline dbs

  • Betatester
  • **
  • Posts: 8924
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: Help with menu?
« Reply #1 on: June 27, 2022, 12:12:15 PM »
Hi, try
Code: [Select]
$aStart         = SM2_ROOT+$Multilang,
And take a look at the DefaultTemplate.
Logged
https://onkel-franky.de

Offline rumen

  • Posts: 480
  • Gender: Male
Re: Help with menu?
« Reply #2 on: June 27, 2022, 01:32:24 PM »
No, without +1 after sm2_root it shows just the Language and nothing happens, just try to download some html file when click.
Logged

Offline rumen

  • Posts: 480
  • Gender: Male
Re: Help with menu?
« Reply #3 on: June 27, 2022, 01:38:16 PM »
This is what I mean
Logged

Offline dbs

  • Betatester
  • **
  • Posts: 8924
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: Help with menu?
« Reply #4 on: June 27, 2022, 02:42:07 PM »
Quote
And take a look at the DefaultTemplate.
Do this.
Search in the index.php for $Multilingual. This is also a number, therfore makes your solution with +1+Multilingual no sense.
You should find a code part where $Multilingual becomes 1 or 0.
Logged
https://onkel-franky.de

Offline rumen

  • Posts: 480
  • Gender: Male
Re: Help with menu?
« Reply #5 on: June 27, 2022, 03:37:52 PM »
I think I set that:

Code: [Select]
<?php

/* -------------------------------------------------------- */
// Must include code to stop this file being accessed directly
if (!defined('SYSTEM_RUN')) {header($_SERVER['SERVER_PROTOCOL'].' 404 Not Found'); echo '404 File not found'; flush(); exit;}
/* -------------------------------------------------------- */
ob_start();  //fetch MainContent
page_content(1);
$page_contentMain = \ob_get_clean();
ob_start();  //fetch original header content
page_content(2);
$page_contentTeaser = \ob_get_clean();
ob_start();  //fetch original header content
page_content(3);
$page_contentSidebar = \ob_get_clean();
$sPageLang    = strtolower(isset($wb->page) || ($wb instanceof frontend) ? $wb->page['language'] : 'BG');
$iPageId = (defined('PAGE_ID') ? PAGE_ID : 0);

// TEMPLATE CODE STARTS BELOW
?>

And that

Code: [Select]
<?php
if (!function_exists('LangPadeId')) {function LangPadeId(){return $iPageId;}}
// to show flags in frontend
    
$iMultiLang = 0;$sMultiLang = ''; if (function_exists('language_menu')){$sMultiLang = language_menu('png',false); $iMultiLang = intval(!empty($sMultiLang) ? 1 : 0);}
    if (
function_exists('LangPadeId')&&$iMultiLang) {
?>
Logged

Offline rumen

  • Posts: 480
  • Gender: Male
Re: Help with menu?
« Reply #6 on: June 27, 2022, 04:00:48 PM »
Solved! The problem was in a JS for a slider. It made a conflict somehow.

Thanks a lot for the help!!!
Logged

Offline hgs

  • WebsiteBaker Org e.V.
  • **
  • Posts: 1892
    • EFG MG
Re: Help with menu?
« Reply #7 on: June 27, 2022, 07:59:56 PM »
Question: Is the site multilingual, or is there only the one language, as seen in the picture?
Logged
LG Harald

"Fange nie an, aufzuhören - höre nie auf, anzufangen." Marcus Tullius Cicero (106-43 v.Chr.)

"Never begin to stop - never stop beginning." Marcus Tullius Cicero (106-43 BC)

Offline rumen

  • Posts: 480
  • Gender: Male
Re: Help with menu?
« Reply #8 on: June 27, 2022, 09:03:37 PM »
It is multilingual BG / EN, but still didn't show the both languages on the screen, but they are setup inside
Logged

  • Print
Pages: [1]   Go Up
  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.11.x) »
  • General Help & Support (Moderator: Boudi) »
  • Help with menu?
 

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