Wordpress Themes - WP Forum at BFA
There will be no more development for Atahualpa (or any other theme), and no support. Also no new registrations. I turned off the donation system. I may turn the forum to read only if it gets abused for spam. Unfortunately I have no time for the forum or the themes. Thanks a lot to the people who helped in all these years, especially Larry and of course: Paul. Take care and stay healthy -- Flynn, Atahualpa developer, Sep 2021

Wordpress Themes - WP Forum at BFA » WordPress Themes » Atahualpa 3 Wordpress theme » Page & Category Menu Bars »

Don't want main categories on menu bar to be click-able


  #1  
Old Oct 26, 2009, 08:36 AM
kmagyarics
 
25 posts · Oct 2009
I have a menu bar at the top of my site (www.trywine.net/wordpress) with a few categories (like Writings) with sub categories (Articles and Newsletter.) I want readers to be able to click on Articles and Newsletters and have them go to those pages, but I don't want the site to take them to the general Writings page. How can I make that not clickable, and just a title, I guess? Thanks!
  #2  
Old Oct 27, 2009, 05:19 PM
krystyna
 
121 posts · Apr 2009
I'm looking for an answer to the same question - to make my drop-down menu items clickable, but the main menu item above that drop down a "non-page." I have several menu items with no drop-downs, only menu item "Products" has a drop-down below it.
  #3  
Old Oct 27, 2009, 05:22 PM
krystyna
 
121 posts · Apr 2009
Never mind, I just found the trigger in the obvious place - under "Page Menu Bar."

I need to seriously get more sleep.
  #4  
Old Nov 9, 2009, 08:17 AM
skizzy
 
2 posts · Nov 2009
Don't want main categories on menu bar to be click-able

The solution describes how to do for PAGE menu bars, but the initial question was related to CATEGORY menu bars.

So please let me ask again how to disable the link for first level parent items in category menu bar?

Are there any plans to add the "Don't link first level parent items in Page Menu Bar?" feature for categories as well?

Thanks in advance!

Last edited by juggledad; Nov 9, 2009 at 09:00 AM.
  #5  
Old Nov 9, 2009, 09:03 AM
juggledad's Avatar
juggledad
 
23,765 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
You could look at the code in bfa_hor_pages.php and see if you could get it to work in bfa_hor_cats.php

That is a good suggestion about adding it to the 'Category Menu Bar', hopefully Flynn wil do it.

If you get the code to works, please publish it and I'll, point flynn at this post.
__________________
"Tell me and I forget, teach me and I may remember, involve me and I learn." - Benjamin Franklin
Juggledad | Forum Moderator/Support

Last edited by juggledad; Nov 12, 2009 at 02:22 PM.
  #6  
Old Nov 12, 2009, 06:46 AM
skizzy
 
2 posts · Nov 2009
Hi juggledad, that's very difficult for a non coding noob like me. Here's what I tried out:

The controlling funktion in bfa_hor_pages.php seems to be this one:

Code:
if ( $bfa_ata['page_menu_1st_level_not_linked'] == "Yes" ) {
		$list_pages_string = preg_replace("/<li class=\"(.*?)><a href=\"(.*?)\"(.*?)\n<ul>/i","<li class=\"rMenu-expand \\1><a href=\"#\" onclick=\"return false\"\\3\n <ul class=\"rMenu-ver\">",$list_pages_string);
	} else {
		$list_pages_string = preg_replace("/<li class=\"(.*?)\n<ul>/i","<li class=\"rMenu-expand \\1\n <ul class=\"rMenu-ver\">",$list_pages_string);
	}
Because I have no idea where the variable
Code:
$bfa_ata['page_menu_1st_level_not_linked']
is set, I tried the short way and took the 'If...="yes"-function', edited it for cats and inserted into bfa_hor_cats.php before the line
Code:
$list_cat_string = wp_list_categories('orderby=' . $sort_order ...
as follows:

Code:
$list_cat_string = preg_replace("/<li class=\"(.*?)><a href=\"(.*?)\"(.*?)\n<ul>/i","<li class=\"rMenu-expand \\1><a href=\"#\" onclick=\"return false\"\\3\n <ul class=\"rMenu-ver\">",$list_cat_string);
- Without any effect. - What's wrong?
  #7  
Old Nov 16, 2009, 11:55 AM
Chief
 
1 posts · Nov 2009
Quote:
Originally Posted by kmagyarics
I have a menu bar at the top of my site (www.trywine.net/wordpress) with a few categories (like Writings) with sub categories (Articles and Newsletter.) I want readers to be able to click on Articles and Newsletters and have them go to those pages, but I don't want the site to take them to the general Writings page. How can I make that not clickable, and just a title, I guess? Thanks!
I visited your page and it looks like you found the solution to the issue. Can you tell me what you did? Thanks!
  #8  
Old Dec 15, 2009, 01:44 PM
Silverthread
 
1 posts · Nov 2009
I too would like to see a check box solution for the category menu, like the pages menu has, for not linking parent items, unless it has no children.

But in the meantime, I need a solution now that will work. Switching to pages instead of posts is not an option.

Thank you for your swift response.

Silverthread
  #9  
Old Jul 31, 2010, 06:22 AM
True
 
11 posts · Jul 2010
Cape Town, South Africa
has anyone got a fix for this please?

I can't get the latest version of Atahualpa but I have the version before that. Please tell me what to do to get top level parent category items non clickable.

Bookmarks

Tags
page bar

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Can I make pages only display main categories and not sub categories buddha Page & Category Menu Bars 0 Oct 24, 2009 06:53 PM
Main menu in left bar needs to have roll over effect shumes1025 Page & Category Menu Bars 0 Oct 12, 2009 01:20 PM
menu tab doesnot response to the click? chizi Page & Category Menu Bars 0 Aug 1, 2009 11:50 AM
[SOLVED] Don't show sub-pages for a main page on my menu bar jockoe Atahualpa 3 Wordpress theme 1 Jul 13, 2009 12:28 PM
[SOLVED] my 'categories' in category menu bar disappear?? when switched from 3.3.2 to ppat2 Page & Category Menu Bars 1 May 21, 2009 08:23 PM


All times are GMT -6. The time now is 04:37 AM.


Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.