Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $(' ul').each(function(){
- var list=$(this),
- select=$(document.createElement('select')).insertBefore($(this).hide());
- $('>li a', this).each(function(){
- var target=$(this).attr('target'),
- option=$(document.createElement('option'))
- .appendTo(select)
- .val(this.href)
- .html($(this).html())
- });
- select.change(function(){
- //alert('url = ' + this.value );
- window.location.href = this.value;
- })
- list.remove();
- });
Add Comment
Please, Sign In to add comment