Element ID in each menu item and subenu item in responsive sidebar menu

Issues related to hyperlinks and web site navigation.
Forum rules
PLEASE READ THE FORUM RULES BEFORE YOU POST:
viewtopic.php?f=12&t=1901

MUST READ:
http://www.wysiwygwebbuilder.com/links.html
Post Reply
liurudys
 
 
Posts: 6
Joined: Sat Mar 11, 2023 12:46 pm

Element ID in each menu item and subenu item in responsive sidebar menu

Post by liurudys »

Dear Pablo and Crispy68,

Please help, what if I want to do or provide an "Id" element for each menu item or submenu item when I design with WWB for the Responsive Sidebar menu extension?

Image
User avatar
crispy68
 
 
Posts: 2737
Joined: Thu Oct 23, 2014 12:43 am
Location: Acworth, GA
Contact:

Re: Element ID in each menu item and subenu item in responsive sidebar menu

Post by crispy68 »

Why are you wanting to add an ID to each menu link? What are you trying to do exactly? I think you will need to use javascript to add an ID to each link.
liurudys
 
 
Posts: 6
Joined: Sat Mar 11, 2023 12:46 pm

Re: Element ID in each menu item and subenu item in responsive sidebar menu

Post by liurudys »

Dear Crispy68,

Because I want to use it to create dynamic menus using the TMS Web Core Framework and design WWB as the html template so that it relates to element ID so that it can be used to display visible or not visible based on the user menu that is given access rights, how about in WWB how do I put each ID element in each link via javascript?
User avatar
Pablo
 
Posts: 21578
Joined: Sun Mar 28, 2004 12:00 pm
Location: Europe
Contact:

Re: Element ID in each menu item and subenu item in responsive sidebar menu

Post by Pablo »

There is no option to add an ID to individual menu items.
This will require a custom script.
liurudys
 
 
Posts: 6
Joined: Sat Mar 11, 2023 12:46 pm

Re: Element ID in each menu item and subenu item in responsive sidebar menu

Post by liurudys »

Dear Pablo,

Ok, Thanks for the suggestion and now I have a solution with javascript :

var dropdownToggle = document. querySelector('.dropdown-toggle');
if (dropdownToggle && dropdownToggle.textContent.trim() === 'Setting') {
dropdownToggle.id = 'dropdown-toggle';
}
Post Reply