How do I customize a Joomla Menu? I have a MainMenu with 1 row 1 item menu. I want to customize the menu with example style: 1 item 2 row. (each row each text field).
Now:
<ul class="menu">
<li class="item-464">
Home
</li>
<li class="item-444 active deeper parent">
About
</li>
</ul>
To:
<ul class="menu">
<li class="item-464">
<a href="#">
<span style="display:block">Home</span>
<span style="display:block,font-size:10px">Home</span>
</a>
</li>
<li class="item-444 active deeper parent">
<a href="#">
<span style="display:block">About</span>
<span style="display:block,font-size:10px">About</span>
</a>
</li>
</ul>
You just need to assign the items with a Parent Item of the first level in Menu Manager > Main Menu > Edit Menu Item which will create a menu tree as you add sub items.
Related
Page Speed Insights is giving me the following error message for Accessibility:
Lists do not contain only li elements and script supporting elements (script and template)
Below are the code snippets that are generating this message. I'm not quite sure what needs to be done here to stop generating the errors, any advice would be much appreciated!
<ul class="slide_tit swiper-pagination-clickable swiper-pagination-bullets">
<li class="swiper-pagination-bullet" tabindex="0" role="button" aria-label="Go to slide 1">
<li class="swiper-pagination-bullet" tabindex="0" role="button" aria-label="Go to slide 2">
<li class="swiper-pagination-bullet" tabindex="0" role="button" aria-label="Go to slide 3">
I have a dropdown menu item as below but it shows in the address bar as: index.php#!
How can I rid of the "#!" ?
<li>About
<ul class="nav-dropdown">
<li >Biography</li>
<li >in the news</li>
</ul>
</li>
I want to click and open multiple plus buttons and print out their texts. Here is the code that I have:
from selenium import webdriver
chrome_path=r"G:\My Drive\chrome_driver\chromedriver_win32\chromedriver.exe"
driver=webdriver.Chrome(chrome_path)
driver.get('https://meshb.nlm.nih.gov/treeView')
for links in driver.find_elements_by_css_selector('a.ng-scope'):
links.find_element_by_xpath("following-sibling::span").click();
for sublinks in links.find_elements_by_xpath("//*[#class='ng-scope']/span"):
print(sublinks.text)
here is what I see! the nodes' text is duplicated! and the code cannot open all the plus buttons. Only the first level plus buttons are opened, how can I change my code to be able to open all plus buttons, and once every plus button is open, I see the node'stext along with the whole content that is associated with it?
A part of html looks like this:
<a class="ng-scope">
<span class="ng-binding ng-scope">Anatomy [A]</span>
</a>
<ul class="treeItem ng-scope">
<li class ="ng-scope" >
< a class ="ng-scope" href="/record/ui?ui=D001829" >
< span class ="ng-binding ng-scope" > Body Regions[A01] < / span >
</a>
</li>
< li class ="ng-scope" >
<a class ="ng-scope" href="/record/ui?ui=D001829" >
< span class ="ng-binding ng-scope" > Cardio Vascular< / span >
</a>
<ul class="treeItem ng-scope">
<li class="ng-scope">
<a class="ng-scope" href="/record/ui?ui=D015824">
<span class="ng-binding ng-scope">Blood-Air Barrier [A07.025]</span>
</a>
<ul class="treeItem ng-scope">
<li class="ng-scope">
<a class="ng-scope" href="/record/ui?ui=D018916">
<span class="ng-binding ng-scope">Blood-Aqueous Barrier [A07.030]</span>
</a>
</li>
</ul>
</li>
</ul>
</li>
</ul>
I am trying to select a time from a time picker on a website with the excel VBA code below. While the code loops through it does not select 09. What am I doing wrong? Website code also below.
Set e = appIE.document.getElementbyid("timepicker-pickup").getElementsByTagName("li")
For Each e In e
If e.innerHTML = "09" Then
e.Click
End If
Next
Website code:
<div class="timepicker" id="timepicker-pickup">
<div class="arrow"></div>
<div class="icon close-btn"></div>
<div class="inner-time-picker clearfix">
<div class="section hours">
<div class="up-arrow"><span class="icon arrow"></span></div>
<div class="selectors">
<ul>
<li data-value="00">00</li>
<li data-value="01">01</li>
<li data-value="02">02</li>
<li data-value="03">03</li>
<li data-value="04">04</li>
<li data-value="05">05</li>
<li data-value="06">06</li>
<li data-value="07">07</li>
<li data-value="08" class="selected">08</li>
<li data-value="09">09</li>
<li data-value="10">10</li>
<li data-value="11">11</li>
</ul>
</div>
Try this:
Dim iL as iHTMLElement
Dim e As IHTMLElementCollection
Set e = appIE.document.getElementbyid("timepicker-pickup").getElementsByTagName("li")
For Each iL In e
If il.innerText = "09" Then
iL.Click
End If
Next iL
You can use querySelector of:
appIE.document.querySelector("#timepicker-pickup *[data-value='09']").Click
No loop required.
I'm having trouble wrapping my head around how to create a dynamic menu with GWcode categories in ExpressionEngine. I would like the menu to go a certain depth only for current {segment_2} (parent) category and the rest of the parent categories to just stay a depth of 1.
For instance, if the url was: domain.com/products/medical-tables-cabinets/eta-classic-series/ it would output this:
<ul class="nav-menu">
<li>Power Tables</li>
<li class="active submenu">Medical Tables & Cabinets
<ul class="nav-submenu">
<li>ETA Alpha Series</li>
<li class="active submenu">ETA Classic Series
<ul class="nav-submenu">
<li>Entry A</li>
<li>Entry B</li>
<li>Entry C</li>
</ul>
</li>
<li>Style Line Cabinet Models</li>
<li>Echo Image Series</li>
<li>Bariatric Series</li>
<li>Family Practice</li>
<li>Treatment & Bedside Cabinets</li>
<li>Managed Care Quick Cabinets</li>
<li>Recovery Couches</li>
</ul>
</li>
<li>Pediatric Equipment</li>
<li>Medical Seating</li>
<li>Blood Drawing Chairs</li>
<li>Tubular Steel & Accessories</li>
<li>Physical Therapy Equipment</li>
<li>Kangoo by Clinton</li>
<li>Training Room Furnishings</li>
<li>Index by Model #</li>
<li>Clinton-Eco Tables</li>
</ul>
I got it working, but I still need to go a little deeper. Here is the basic concept:
{exp:gwcode_categories
channel="products"
style="linear"
}
{if depth1_start AND segment_2 != cat_url_title}
<li>{cat_name}</li>
{/if}
{if depth1_start AND segment_2 == cat_url_title}
<li class="active submenu">{cat_name}
<ul class="nav-submenu">
{/if}
{if depth == 2 AND segment_2 == parent_url_title}
<li{if segment_3 == cat_url_title} class="active"{/if}>{cat_name}</li>
{/if}
{if depth1_end AND segment_2 == parent_url_title}
</ul>
</li>
{/if}
{/exp:gwcode_categories}