JQuery Dropdown Menu changing to toggle menu
Hello,
i have created a jquery mobile dropdown menu with the following configuration:
// Create the dropdown base
$("<select />").appendTo("nav");
// Create default option "Navigation"
$("<option />", {
"selected": "selected",
"value" : "",
"text" : "Navigation"
}).appendTo("nav select");
// Populate dropdown with menu items
$("nav a").each(function() {
var el = $(this);
$("<option />", {
"value" : el.attr("href"),
"text" : el.text()
}).appendTo("nav select");
});
$("nav select").change(function() {
window.location = $(this).find("option:selected").val();
});
This menu i want to chance in a toggle menu (Example here:
http://www.jqueryscript.net/menu/Mob...uery-CSS3.html ) - is there a possibility if i would only chance the Script code and CSS Code?
Thanks for help.