Search code examples
phpjqueryhtmljquery-uiopera

jquery.ui.selectmenu redirects to index page instead of submitting form


I use jquery.ui.selectmenu.js plugin for custom selects on my website.
My select has binded onchenge event which does $(this).closest('form').submit();
The problem is that in Opera it does not submit the form - it redirects to index page and adds #nogo to url.
I find the reason in plugin.
There are such pieces of code there:

    this.newelement = $( '<a />', {
        'class': this.widgetBaseClass + ' ui-widget ui-state-default ui-corner-all',
        'id' : this.ids[ 1 ],
        'role': 'button',
        'href': '#nogo',
        'tabindex': this.element.attr( 'disabled' ) ? 1 : 0,
        'aria-haspopup': true,
        'aria-owns': this.ids[ 2 ]
    });

The question is - what should I replace #nogo with to fix it ?
Thanks.


Solution

  • The answer is javascript:void(0);