- This topic has 6 replies, 2 voices, and was last updated 15 years, 6 months ago by booobooo.
-
AuthorPosts
-
May 13, 2009 at 9:03 pm #806boooboooMember
I’m working on this layout: http://tinyurl.com/qgbayg
and am coming up against an slight issue. If you click through to either the gallery or the framing section (doesn’t matter) you’ll see the menu bar at the top. The first two options are "Exhibits" (a category) and "Gallery" (a page)
I want the categories that list under "Exhibits" to actually appear in the "Gallery" dropdown:
GALLERY (page)
-CURRENT (category)
-UPCOMING (category)
-PAST (category)
-SUBMISSIONS (page)
-MAYBE MORE OPTIONS (pages)The two easy ways of doing this have bad consequences:
a) I can use the page2cat plugin to make current, past and upcoming pages and then stick the category links in there. There is limited functionality there, however, and it just makes a huge mess of redundant looking posts that no one but me will ever understand.
b) I can use the multi-level menu option for a custom menu and just hardwire that drop down so that it has the options I want. However, if someone wants to add something to the "Gallery" dropdown it won’t dynamically add it. Similarly, if the permalinks or titles change the custom menu won’t know it.
So basically, I’m wondering if there’s any way to rig the multi-level menu plug-in to do it? If not I’ll probably settle for option b since at least it’s invisible for the end user.
Thanks!
May 15, 2009 at 8:31 am #6177imported_RyanMemberYou can use the ‘Categories (single dropdown)’ option and then specify a URL and title for the top level menu item for the category. As long as you specified the page name and URL for that top level item then it should behave as you want it to.
May 15, 2009 at 11:28 am #6178boooboooMemberHey that’s pretty cool. Now look again. I have two "Gallery" options: One what you just described and one for the Gallery page with its subpages. Any way to combine them? Any way to get those gallery subpages to appear under my new category list with its modified top level menu item?
May 16, 2009 at 11:05 am #6179imported_RyanMemberYes you could do that, but it would require some custom scripting to get it working.
May 19, 2009 at 1:28 pm #6180boooboooMemberYou’re right. I added this to line 106 of core.php:
… wp_list_pages(‘child_of=11&title_li=’);"</ul></li>n";
And that did it. Sweet! Now you can see a mix of cats and pages in the same drop down.
Thanks for the guidance.
May 20, 2009 at 6:17 am #6181imported_RyanMemberI’ll consider adding another option for this in a future version to save you having to hack the core plugin files to do it.
May 20, 2009 at 11:27 am #6182boooboooMemberSounds good! I’ll have to keep an eye on updates in the meantime because obviously I don’t want to lose my changes.
If you want to see it in action I’ve moved it: http://tinyurl.com/qhqna2
-
AuthorPosts
- You must be logged in to reply to this topic.