Drupal: Add Archive to Primary Links as SubNav - drupal

My site has news articles that I want to add to the sub-nav under "News" as years.
News
2010
2009
But I only want the current year and 1 previous year. And I need it to happen automatically.
I know how to create a page view that will only show news articles from the previous year, I just don't know how to change the Menu & Node Title to the archived year.

How about creating a custom views block display that prints out you menu as desired?

Okay, got it.
You might try the Views Build Menu module http://drupal.org/project/views_build_menu
It seems to add a menu display called "menu" which allows you to set a parent menu item under which you views-generated menu should appear.
Here's the documentation (with interesting screenshots) for Views Build Menu: http://drupal.org/node/831564

Related

Wordpress Category to Menu

I have created several categories with sub-categories, I want to display the category in a menu so I created the menu inside appearance-->Menus, now what I want to be displaying is the created categories(with the respective sub-categories) in the menu. I went to the categoryName, when I selected the Category1 with the hope of getting all the sub-categories automatically, I only get the Category1 back, when I clicked view all-->select all-->add to menu unfortunately it shows all the categories with the sub-category at the same level. Please how can WordPress newbie, that have close to zero knowledge of php programming achieve this task? Or is there any plugin for that? Oh I forgot to mention that the only option I'm seeing is to start dragging(over 200 categories and still counting) and arranging in the menu. Please is there any other way to hasten my task?
Im the menu, you can drag and drop to arrange menus. Drag a menu to the right a bit to make it a sub menu under a certain menu

WP showing two active menu items at the same time

One of the pages on my site is setup to display posts from a specific category. When that category is active, the blog menu item also shows as active, displaying two active menu items at the same time. I've tried excluding the category, but that hasn't worked.
It may be a hotlinking issue.
s
You'll see from this site at http://www.wildpop.ca (Wildpop dot.ca), when you choose "SEO" from the menu, you are directed to what appears to be the "Monthly Packages" page. The SEO link in the menu does not have it's own page. It is a direct link to a section named (seo_direct) that is contained in a different page, but when you look at the menu again - both menu options are highlighted as "Active Page".
Make sure this isn't the issue for you.

Custom top menu in Wordpress

I'd like to have a menu like the one in this demo http://yoko.elmastudio.de/, I mean the one with Category 1, sub category 1, sub category 2, .... Looking in the setting menu (into the admin dashboard) I can't find anything useful as there are only widgets that I can drag and drop in the 2nd or 3rd column but not in the top and using all the blog width.
I've done some Google and WP official website search for plug-ins but I didn't find what I was looking for...does anyboudy know how can I realize a top menu like the link posted above?
If your theme supports it and you are using WP 3.0 or above the custom menus can be created by clicking the "Menus" item under the "Appearance" menu.
WordPress custom menus allow you to create multiple menus and assign pages, categories, custom URL's, etc. as menu items. You can then move them around using a drag and drop interface, allowing you to specify order and organize them hierarchical.
Once you have created the menus, you assign them to a particular "Theme Location" as defined in your theme.
Visit http://codex.wordpress.org/Appearance_Menus_Screen for more information.

How can I hide pages from menus in WordPress?

I only want to show the pages that do not have parents, and link the other pages from their parent pages.
I want to have a simple main menu: Home | Pages | About | Contact
About 8 pages are linked from the Pages page. At the moment, the menu has 12 items, which deforms the layout pretty badly.
I have tried making the pages private, unpublished, and other options, but that doesn't seem to be the way to do it. Is there a way I can just have only parent pages linked in the main menu?
You can edit the menu (under the appearance tab in the dashboard). (you may need to add a new menu and assign it to the main navigation menu. It sounds like you have the defaulted menu set-up.
Once you've added a menu and assigned it to the main navigation, you can uncheck "automatically add top-level elements" or its equivalent, and add/remove menu items. You can also change their hierarchy (independent of actual page hierarchy).
It's all so easy these days. Just Go to appearance>menus>click the little triangle next to the listed page name>click remove> don't forget to save ... all done!
Maybe you didn't set up a custom menu yet. Set up a custom menu first with the desired pages / links. If it doesn't show on your site, check custom memus are enabled in your theme.. this will help you setting up a custom menu: http://www.wpbeginner.com/wp-themes/how-to-add-custom-navigation-menus-in-wordpress-3-0-themes/

WordPress 3 - Problem with menu highlighting

I'm building a site that has a two level menu created with the admin Menu tool. The menu contains links to both Pages and Category lists. It doesn't link directly to Posts. The problem is that when you drill down into a Category list and click to view a single post in that Category, the menu highlighting gets it wrong.
I've tested on a new install of WP3, set up a simple test site with a few pages and posts in 3 categories. All I've changed in the theme is the style.css to highlight the whole path.
http://danwashere.com/wp_dev/
Here's a direct link to view a categorised post here:
http://danwashere.com/wp_dev/2011/07/28/blue-rocks/
Everything is a page, except with the section "Advice Categories" - all those sub items are category lists containing categorised posts - each post is only categorised with a single category. The menu structure is defined entirely in the Menu settings.
On that Blue Rocks page, the menu should be highlighted like this: Advice Categories -> Rocks, but it's highlighting the Sample Page item. And if you rollover the "Advice Categories" menu, you'll see that it is correctly highlighting the "Rocks" menu item.
It seems to me that WP is applying the 'current-post-parent' class to the wrong top menu item, but maybe I'm missing something?
// Edit, rewrite to make it clearer.
It seems as though were both having very similar issues. - Trouble highlighting correct menu parent with wp_nav_menu classes while viewing “single posts”
Im not using categories as links in my menu but I use them to filter content to each page via query_posts...if you examine the output from Wordpress you'll notice its actually placing the current page class onto the incorrect li tag when viewing a single post - Is this happening to you as well?

Resources