Page 1 of 2

pb with menu after migration

Posted: Sat Jul 17, 2010 8:54 pm
by auarstadtt
hello,
sorry if my question is not clear or stupid.
I moved my website from the hosting provider to my computer (mac).
jommla is perfectly installed and I moved with akeeba and the data base with SQL export and import.

the frontpage is ok, I see my database ok with phpmyadmin, but : I don't have any menu and links to the other pages.
In the admin page I see thaht I have all my menus and they should be published but I don't see any of them.
I tried to change the username because with the restore process with akeeba I don't have the same username and password than the joomla base. but it doesn't change anything.
Should I modify the .htaccess ? how ?
I also tried to change the username and passwords with moovlaj15 but it's the same...

thanks a lot for reading me.
Antoine

Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Fri Jul 23, 2010 9:57 am
by ishr
Hi dear,

I updated recently my Joomla version from x.18 to x.20 and I realized that some menu items in the backend are completely empty and some are not.

Into the frontpage, the menus still exists and works.

To be sure that the problem is located into the update files, I made a roll-back and all my menu items comes up again.

What strange isn't it?

ishr

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Fri Jul 23, 2010 10:16 am
by ishr
I found the file who causes problems:
\Joomla_1.5.18_to_1.5.20-Stable-Patch_Package\administrator\components\com_menus\models\list.php

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Fri Jul 23, 2010 2:47 pm
by markluchauer
I have the same issue.

I updated using the Update Manager.

Now, one of my menus is not showing any items, however, the menus still show up in the Menu Manager and are still there and working on my website.

Any suggestions on a fix?

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Mon Jul 26, 2010 8:09 am
by ishr
Dear Markluchauer,

If you have a backup of your website, you can just recover and replace the new file to the old one and you will get again your items in the meantime developers fix the file.

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Tue Jul 27, 2010 9:18 pm
by centsman
Using the menu manager, try removing the spaces in the unique name...

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Fri Jul 30, 2010 8:19 pm
by bigtreegraphics
Hello. My menu items are all also missing after upgrade to 1.5.20. It is only one of my 5 menus, but it is my large, main menu. When I click on the menu it displays zero items, yet the front end is working just fine. How do I get the items to return to the backend so I can edit them? I cannot find the file the other poster referred to.
thanks for your help!

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Sun Aug 01, 2010 9:13 am
by jqv
One of my Joomla websites have 22 menues and a lot of these have space in the names so this bug was a little scary for me... ;)

First I tried to edit all of the names in admin to "correct" Unique Name, like from "My Special Menu" to "my-special-menu" with no success. Still empty menues.

Then I went in to the database with phpMyAdmin an renamed all the menues to the old space names in the table "jos_menu_types", field "menutype".

Finally I uploaded this script from 1.5.18:
administrator/components/com_menus/models/list.php

Now I must remember NOT to edit the menu names until this it fixed.... :p

Found this thread at the Bug tracker.

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Mon Aug 02, 2010 1:25 pm
by bigtreegraphics
Thanks for your post jqv!
I implemented all of your suggestions as you did and still my menu items are missing. There are about 18-20 items in my menu and it is still showing blank on the backend.
The site is supposed to launch later today so I have to start over and recreate the menu unfortunately, I don't have any more time to play with this awful bug. :(((

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Mon Aug 02, 2010 5:58 pm
by jqv
Perhaps it's too late now, but I think the space names is case sensitive too if you are on a unix host. i.e. "My Special Menu " and "my special menu" is different names. Perhaps the fastest way is to create a brand new menu and enter the items again... :-\

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Tue Aug 03, 2010 12:24 am
by wtom
Edited to update status:

I had the same problem with disappearing menus after an .18 to .20 upgrade.

I first tried copying the list.php file from the .18 release as noted above, that let me list the missing menus, but odd things happened when I started trying to edit them. I put back the .20 list.php, and this time changed any spaces to dashes in the Unique Name of the menus listed in the menu manager.

So far, all menus are showing up and editing correctly again.

On a LAMP platform, dunno if it makes any difference but I migrated this site from Joomla 1.x to 1.5.

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Thu Aug 05, 2010 4:24 am
by ChiefGoFor
The problem has to do with the way the new "menutype" input type is used. It works great for new menus, but not for old ones with spaces. As of right now, I recommend:
  • Back up your site
  • Export all of your DB tables using phpMyAdmin (checking Add Drop Tables on export screen)
  • Open the SQL file that you exported
  • Look for the SQL where "jos_menu_types" is (Note: if you used a different DB Prefix, it may not start with jos_).
  • Example SQL you might find:

    Code: Select all

    INSERT INTO `jos_menu_types` (`id`, `menutype`, `title`, `description`) VALUES(5, 'Right Menu', 'Right Menu', '');
  • The first instance of "Right Menu" is the "menutype". This should NOT contain any spaces. In fact, I recommend make it lowercase, converting spaces to a hypen "-".
  • Search the entire SQL file for all instances of "Right Menu" and change them to "right-menu".
  • The tricky part here is that not all places need to be changed. For instance, you do not need to change the "second instance" in the example above, nor do you need to change the module title associated with this module.
  • Once you have made your changes, import the SQL back up to your web site.
If you have any issue, restore a copy of the original SQL file you exported BEFORE you edited it and try again.

I hope that helps. If you have any questions, please let me know.

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Thu Aug 05, 2010 8:35 am
by ishr
Hi there,

Thank you very much, ChiefGoFor, for your help.

Personally, I find your solution a bit tricky, but I am sure that should work!

In my side, I followed your suggestion and rename all my menus with small capitals and replaced the spaces by hyphen. Then, I updated the file "list.php" and everything is working now.

Thanks again,

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Thu Aug 05, 2010 11:23 am
by ChiefGoFor
Ishr,

Forgive me if this response sounds rude. It it unintended. :)
ishr wrote:Personally, I find your solution a bit tricky, but I am sure that should work!
You stated that it should work, but then you admit to following it. Did you fix it using the way I described or some other way? I ask because if your other way is better or easier, people would love to know how. You stated that you renamed all of your menus. That is exactly what I suggested, only I broke it out into smaller steps.

Also, on the whole notion of replacing the list.php file. It has not importance with this issue. I compared the list.php file from 1.5.18 and 1.5.20 and the only major difference has to do with setting a default value for the ordering filter if a valid ordering value is not available.

Again, not trying to be rude, just trying to understand what you did differently. If your method is different, then I would love to have a look. :) Thank you!

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Thu Aug 05, 2010 3:59 pm
by nightshiftc
I ran into this yesterday. After freaking out and finding this very helpful thread, I moused over the info icon and found the suggestion that you do not use spaces in the unique name. I quickly backup the site and db and went on to fix the unique names so they had no spaces. That fixed the problem. Please back up before you make any changes!

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Thu Aug 05, 2010 7:49 pm
by stompwampa
Very helpful! THANK YOU! Fixed everything without a problem!

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Thu Aug 05, 2010 10:20 pm
by masoesa
Is there another fix for this?

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Fri Aug 06, 2010 1:41 am
by ChiefGoFor
To my knowledge, no there is not. It is not just as easy as putting a check in for spaces and changing it in the database... some extensions like joomap reference menus by their menutype. If Joomla automatically changed it, then it would break any sitemaps you created with Joomap.

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Fri Aug 06, 2010 8:04 am
by ishr
ChiefGoFor wrote: You stated that it should work, but then you admit to following it. Did you fix it using the way I described or some other way? I ask because if your other way is better or easier, people would love to know how. You stated that you renamed all of your menus. That is exactly what I suggested, only I broke it out into smaller steps.
Actually, instead going through the db, I made the changes through Joomla menu manager directly.
ChiefGoFor wrote: Also, on the whole notion of replacing the list.php file. It has not importance with this issue. I compared the list.php file from 1.5.18 and 1.5.20 and the only major difference has to do with setting a default value for the ordering filter if a valid ordering value is not available.
Well, in my case I:
1. Updated from 1.5.18 to 1.5.20 then I saw that menu items were missing.
2. Started to roll-back folder by folder, then file by file to find the one who makes the bug.
3. Found that the file "list.php" was in cause: 1.5.18 version --> I get my menu items, 1.5.20 --> I haven't got them.
4. Renamed the unique-name through menu manager
And now with the list.php version 1.5.20 I have all my menu items again.

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Fri Aug 06, 2010 11:16 am
by ChiefGoFor
Hi ishr!

Thank you for clarifying. :)

You might also want to export your database and search for the old menutype to make sure that other extensions are not trying to reference the old names.

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Sat Aug 07, 2010 6:48 am
by crazeann
Hi..all,
found this thread by google...
i have similiar problem with joomla 1.5.20, missing menu items after restoring joomla database from 1.5.18.
i've already check the unique name of menutype in jos_menu_types table, and the records appear to not have any space, just plain "mainmenu"

Do you guys have any resolution..

thanks for help...

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Mon Aug 09, 2010 2:37 pm
by spotya
yup. I just changed the unique name of the offending menu in the menu manager to remove spaces... Instant fix!

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Mon Aug 09, 2010 9:59 pm
by ChiefGoFor
That is great to hear! :)

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Tue Aug 10, 2010 7:20 pm
by chrisurban
Ok, this is interesting - after an update from 1.5.18 to 1.5.20, editing, but not creating, new menu items for a menutype named something else other than mainmenu does not work. These other menutypes did not have spaces, but did have uppercase characters. Creation of a menu item is fine, but then editing with save or apply reverts the item back to the mainmenu menutype. Short of manually editing the item in the jos_menu table, there's no way to get it back to its proper menu.
Anyone else encounter this issue? Any fix, or is a 1.5.20 bug?

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Tue Aug 10, 2010 7:36 pm
by chrisurban
Ok! - followup - the issue is not just spaces in the menutype names, it is ALSO case-sensitive. In our case, we had menus named MainTop, TopLeft, BottomLeft, etc.
Simply updating the names in the Menu manager will do the trick.
Another option, if you are so inclined, is to manually update these in the jos_menu and jos_menutype tables.
Reference: http://groups.google.com/group/joomlabu ... 6239?pli=1
Reference: http://groups.google.com/group/joomlaug ... cfb726d952

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Tue Aug 10, 2010 9:52 pm
by ChiefGoFor
Hi Chris,

You are correct. The menutype has to be lowercase without spaces. Underscores are allowed.

To be more thorough, it only allows:
  • abcdefghijklmnopqrstuvwxyz (lowercase letters)
  • 0123456789 (numbers)
  • - (hyphen)
  • _ (underscore)
Spaces are removed and uppercase letters are made lowercase. The point here is that if you create a new menu type, it will remove spaces and drop the case. If you already have existing menus that violate these rules, it will try to use the "converted" version of their type... which would not match up, thus you have issues.

I hope that clears a little ambiguity up and does not confuse you more. :)

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Wed Aug 11, 2010 8:31 pm
by techivity
The easiest fix for this is to change the unique name of the menu in the menu manager so that it has no spaces in it. Its a pretty quick and easy fix once you find the right forum thread discussing the issue.

Though, checking the release notes, there was no mention of a change that would make menus vanish. That would have been helpful to avoid a difficult situation with the client who's site I updated...I wonder if this was a surprise to the Joomla team? I checked the 1.5.19 release notes and saw no mention of it there either.

Seems like something that should be in the release notes; that there is a change in the code that may cause menus with spaces in their unique names to vanish in the admin panel, and that the fix is to go to menu manager and remove the spaces...or if that's listed in an issue tracking DB, seems like the release notes should reference the DB. Something a bit more proactive than "search google, try several search terms until you find a forum reference with 15 posts with all kinds of suggestions about manipulating SQL statements when there's a quick easy fix from the admin panel..."

(admittedly, bitter - it was very, very uncomfortable to have a client say "the menu is gone")

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Wed Aug 11, 2010 9:04 pm
by ChiefGoFor
techivity (and others),

Not every change is mentioned in the release notes. I will say though that it probably should have been mentioned in the CHANGELOG, which is was not.

The truth of the mater is that during testing of the patch, this combinations of circumstances was never caught. In fact the tooltip (text below) even advises you not to use spaces. It does not however advise against capital letters.
TIPNAMEUSEDTOIDENTIFYMENU=This is the name used by Joomla! to identify this Menu within the code so it must be unique. We recommend that you do not have any spaces in your unique name
Changing from the Administrator as you mentioned will work in a lot of cases (I hesitate to say "most"). Some extensions use the menu type as a reference. I know Joomap is one of them. So, that is one instance where it is not 100% to just use the Administrator.

I hope that helps with the understanding. Thank you for your input. It is great to see the community coming together to help others battle this unfortunate oversight.

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Thu Aug 12, 2010 8:57 pm
by jqv
ChiefGoFor wrote:I hope that helps. If you have any questions, please let me know.
Thank you! I finally came around to edit the SQL file with 22 menues with around a hundred items. When I uploaded it back to the database everything worked perfect in admin again. But instead all of the front end menu items vanished instead! :p

The fix then was to go in to each module for every menu in the Module Manager and set Menu Name, under Module Parameters, it was not set (-Select Menu-). Hope this is helpful if someone else have this problem.

Re: Menu items missing after upgrade v1.5.18 to v.1.5.20

Posted: Thu Aug 12, 2010 9:15 pm
by ChiefGoFor
@jqv,

When you exported the database, you should have (and may still want to) search your entire database for the old Menu Types. The modules in jos_modules would have come up and you could have change them. :)