Submenus – icons and list order

Posted in: Newspaper
Post count: 16

Hi!

1) Do you have a built-in way to list my menu items like in this picture, or should I use CSS?

https://drive.google.com/file/d/1CN_D6VdUp33EThDOC2uroWP1PV8Zacwa/view?usp=sharing

So: The submenus should be listed horizontally and every submenu item of submenu (how do you call them?) should be listed even if the submenu is not active, if the parent menu item is active.

2) Where can I hide this mobile menu icon? I am using Crypto News template and cant find this logo in any Settings. Probably obvious thing to ask, but I have tried to search and not found. 🙂

https://drive.google.com/file/d/1t3bhcpnM34jmO4DFjBrGDmPZmlTw_xqW/view?usp=sharing

3) Also, where can I delete these submenu icons? They do not appear on every submenu, only in the ones without any link.

https://drive.google.com/file/d/1aZ8vEAba0Z8RF8C3NJ6ntrb_SkkF4oX0/view?usp=sharing

Thank you very much!

  • This topic was modified 4 years by geoforum. Reason: just found it :)
Post count: 21065

Hello @geoforum!

1. My recommendation is to use the mega menu page id for a menu that you can build however you want it: https://forum.tagdiv.com/page-menu/

2. This is on your responsive mobile viewport: https://www.screencast.com/t/tGxmk66Q

Thank you!

Post count: 16

Thank you very much!

Is it possible to do a megamenu with tags, not categories?

Post count: 16

Maybe my first picture was not really good one

https://drive.google.com/file/d/1qbLwdgyFBk_5dMB08ipYwdMMEIR3aC3J/view?usp=sharing

Do you mean I could do this best with megamenu? I do not really understand how. 🙂 I want there to be vertical lists of some categories and tags under some headers as submenu items.

I want there just to be text in the menu, not something like this
https://forum.tagdiv.com/wp-content/uploads/2015/05/Mega-Menu.png

Post count: 21065

Hello @geoforum!

Yes, you can use the element called ” Categories/tags list ” and place it in your page mega menu design. Create the page with the TagDiv Composer and you can align the submenus how you’ll like. Please check the documentation I just provided you above, it will help you step by step.

Thank you!

Post count: 16

Thank you very much, this helped a lot!

Post count: 16

Okay, I feel stupid to ask this but I do not get it.

So I make a menu header, then I make submenus and make the submenus to be page mega menu – right? Until this I am good.

Then, how can I add the category/tag-element to the mega-menu? It does not “go” there, but rather next to the main menu than inside. I tried to make inline row but the same thing. How can I add elements inside the menu?

Thank you in advantance!

Post count: 16

Got it. I have to put the items in the page and they will automatically be in the menu. Thank you for the help, this looks like a very handy tool!

Post count: 16

I have one more question. When I do have category/tag-list item with hierarcial tags, is there a way to filter it with only parents ID so the children are displaying? I need to have it like that, if someone ads new children to the parent tag, the child will be automatically in the menu. Should I modify the theme code to make this possible?

I made my tag list hierarcial with this snippet if it does matter:

`function wd_hierarchical_tags_register() {

// Maintain the built-in rewrite functionality of WordPress tags

global $wp_rewrite;

$rewrite = array(
'hierarchical' => false, // Maintains tag permalink structure
'slug' => get_option('tag_base') ? get_option('tag_base') : 'tag',
'with_front' => ! get_option('tag_base') || $wp_rewrite->using_index_permalinks(),
'ep_mask' => EP_TAGS,
);

// Redefine tag labels (or leave them the same)

$labels = array(
'name' => _x( 'Tags', 'Taxonomy General Name', 'hierarchical_tags' ),
'singular_name' => _x( 'Tag', 'Taxonomy Singular Name', 'hierarchical_tags' ),
'menu_name' => __( 'Hierarkiset tagit', 'hierarchical_tags' ),
'all_items' => __( 'All Tags', 'hierarchical_tags' ),
'parent_item' => __( 'Parent Tag', 'hierarchical_tags' ),
'parent_item_colon' => __( 'Parent Tag:', 'hierarchical_tags' ),
'new_item_name' => __( 'New Tag Name', 'hierarchical_tags' ),
'add_new_item' => __( 'Add New Tag', 'hierarchical_tags' ),
'edit_item' => __( 'Edit Tag', 'hierarchical_tags' ),
'update_item' => __( 'Update Tag', 'hierarchical_tags' ),
'view_item' => __( 'View Tag', 'hierarchical_tags' ),
'separate_items_with_commas' => __( 'Separate tags with commas', 'hierarchical_tags' ),
'add_or_remove_items' => __( 'Add or remove tags', 'hierarchical_tags' ),
'choose_from_most_used' => __( 'Choose from the most used', 'hierarchical_tags' ),
'popular_items' => __( 'Popular Tags', 'hierarchical_tags' ),
'search_items' => __( 'Search Tags', 'hierarchical_tags' ),
'not_found' => __( 'Not Found', 'hierarchical_tags' ),
);

// Override structure of built-in WordPress tags

register_taxonomy( 'post_tag', 'post', array(
'hierarchical' => true, // Was false, now set to true
'query_var' => 'tag',
'labels' => $labels,
'rewrite' => $rewrite,
'public' => true,
'show_ui' => true,
'show_admin_column' => true,
'_builtin' => true,
) );

}
add_action('init', 'wd_hierarchical_tags_register');`

  • This reply was modified 4 years by geoforum.
  • This reply was modified 4 years by geoforum.
Post count: 21065

Hello @geoforum!

You can use this ID filter in order to display the categories you need there: https://www.screencast.com/t/toLrXgDM7g7

Thank you!

Post count: 16

Hei Bettina!

Thank you but I meant to ask, is it possible to display child tags with just one number, the parent tag?

I made my tags hierarcial, so they now have children and parents. So If I have parent tag “ID=1” and lots of child tags “ID=2” “ID=3″ …”ID=25”, is it somehow possible to display them all just writing tag ID number 1 to this filter.

This would be important in this spesific site, for there will be lots of new tags and the one using the site should not need not modify this filter every time they add a new tag. So I need to have parent-child hierarchy and they only need to add their new tag to the right parent.

In what file should I modify the code if that is needed?

Post count: 21065

Hello @geoforum!

You should add there each ID of your child tags or parent tags. Try to modify the filter function from \wp-content\plugins\td-composer\legacy\Newspaper\includes\shortcodes\td_block_categories_tags.php

Thank you!

Viewing 12 posts - 1 through 12 (of 12 total)
The forum ‘Newspaper’ is closed to new topics and replies.