WebsiteBaker Community Forum

WebsiteBaker Support (2.8.x) => Templates, Menus & Design => Topic started by: applepie on February 29, 2008, 03:40:28 PM

Title: Show menu_2 dissappeared
Post by: applepie on February 29, 2008, 03:40:28 PM
Hi, I installed the show menu mod and it all works great. The home link was the parent of my submenus. The submenu were showing on all my pages which was what I wanted. I then accidently deleted the home link and that deleted all my submenus as well. I thought I could recreated the pages and that would solved the problems. But none of the submenus are showing on my site now. Can someone please help? How do I get all my submenu to show now? Thanks in advance.
Title: Re: Show menu_2 dissappeared
Post by: ruebenwurzel on February 29, 2008, 06:18:50 PM
If you delete a root page, the system warns you that this also deletes all subpages. So if you do it, yhou should know the consequence. If all subpages are deleted, you have to recreate them.

Matthias
Title: Re: Show menu_2 dissappeared
Post by: applepie on March 01, 2008, 03:10:37 AM
Hi, i recreated all the page and subpages again. I can see and edit the pages in my admin but the subpages are not visible on my site. I am puzzled.
Title: Re: Show menu_2 dissappeared
Post by: ruebenwurzel on March 01, 2008, 08:16:02 AM
Hello,

are the files in the pages dir?

Matthias
Title: Re: Show menu_2 dissappeared
Post by: applepie on March 01, 2008, 11:46:30 AM
Hi Matthias,

Everything is set as how it was done before, eg:

Home
 - Subpage 1
 - Subpage 2
 - Subpage 3

I can see the Home link on the main but not the subpages on my site. I can see and edit everything from the admin. What do you mean if they are in page dir?
Title: Re: Show menu_2 dissappeared
Post by: ruebenwurzel on March 01, 2008, 06:34:27 PM
Hello,

for every page you generate there needs to be a corresponding file it the /pages dir. So look with ftp, if for all pages there is a corresponding file there. In WB admin the content is only read from database, in frontend the file in pages dir is necessary to display the content.

Matthias
Title: Re: Show menu_2 dissappeared
Post by: applepie on March 02, 2008, 10:34:42 AM
Hi Matthias,

This is what I see on ftp:

The filename 'Home.php' (<?php $page_id = 22;.... )

Corresponding folder 'Home' with filenames in the folder: Who.php (<?php $page_id = 25;.....)

I am not sure what to look for. The structure and ID seems ok.

Thanks for looking into it. Cheers :)

Title: Re: Show menu_2 dissappeared
Post by: applepie on March 02, 2008, 11:47:22 PM
Anyone got an answer?
Title: Re: Show menu_2 dissappeared
Post by: Ruud on March 03, 2008, 12:08:55 AM
You could start by just setting show_menu2()  (without any parameters), just to see if they are there.
That should show subpages when you are on the parent of that page. (also the parent pages)

The only reason I cloud think of is that the first parameter is wrong. This is used when there are different menu groups. Using 0 uses "all"menu groups.

Maybe you can show your show_menu2 command to us?

Cheers
Ruud
Title: Re: Show menu_2 dissappeared
Post by: applepie on March 03, 2008, 03:05:34 PM
There may be a bug somewhere ?? Everything works fine until I accidentally deleted the page with subpages. I thought all I need to do is to add the pages again. Unfortunately that is not the case. Here is the code on my webpages.

<?show_menu2(0, 1, SM2_ALL, SM2_ALL); ?>

That should show all the pages with subpages. Why did it suddenly stopped working?

Title: Re: Show menu_2 dissappeared
Post by: lausianne on March 03, 2008, 05:02:05 PM
Hi,

this sounds a bit like my problem that I reported earlier today. Which version of WB do you use? I encoutered pages not showing up in the menu with 2.7 today, never before with 2.6. (both show_menu and show_menu2)

Cheers,
Ralf.
Title: Re: Show menu_2 dissappeared
Post by: applepie on March 03, 2008, 05:33:25 PM
At least I know I am not the only one with the problem or imagining it. I am using 2.6.7. I never had any problems before. This is so frustrating as I cant see why it should happen. So many people viewing here but no one has an answer. Are you still having problem with yours?
Title: Re: Show menu_2 dissappeared
Post by: Ruud on March 03, 2008, 05:42:51 PM
Just a wild guess..

Are your submenu pages in a different language than your root page?

For me, I have lots of sites running with WB 2.6.7. I never had this problem. (would not go to sleep before it was solved also  :wink: )
(I would love to have a look inside your problem.)

Cheers,

Ruud
Title: Re: Show menu_2 dissappeared
Post by: lausianne on March 03, 2008, 06:31:12 PM
Hi Ruud,

yes, I do. Three languages.

I switch the system language depending on the part of the website I work on. Like this, new pages are automatically set to the right language.

Ahem, what exactly is THE root page? I have three pages on the top level (one language each), then many pages on the second level.

Problem's still there, I'm going to sleep now anyway ...

Cheers,
Ralf.


Title: Re: Show menu_2 dissappeared
Post by: lausianne on March 04, 2008, 10:55:08 AM
GOT IT!!!

I had to disable the setting "Page languages" in Settings. I thought I had to turn it ON to use different languages ...
Maybe once I understand it can even become useful ...
Hopefully this works for you, too, applepie.

Cheers,
Ralf.

Edit:
Now I read the manual about this setting:

Quote
Users that are not logged in will see only the pages in the language chosen as the default for the site (Admin->Settings->Default Settings->Language).

In my opinion this would become really useful if users could choose their language without logging in. That would make multilanguage sites supersimple to design.
Title: Re: Show menu_2 dissappeared
Post by: applepie on March 06, 2008, 11:27:25 PM
Dear Ralf,

I wish its that simple. I didnt touch anything else. The menu just disappeared when I accidentally deleted the links. Anyone else found the answer?  :cry:
Title: Re: Show menu_2 dissappeared
Post by: applepie on March 08, 2008, 08:08:37 PM
OK, I fixed the problem now. There must be some bugs somewhere. I replaced:

<?php show_menu2(0, 1, SM2_ALL, SM2_ALL); ?>   with

<?php show_menu2(0, SM2_ROOT+1, SM2_START, SM2_ALL);?>

The first instance works fine until I accidentally deleted my menu items.

Everything starts to work as it should now. Very strange!