Hyperlink not working in jQuery Tabs
I have the following code: http://pastebin.com/gg4kgGKz
On line 2开发者_运维问答40 of the pastebin code, I have tried to add a hyperlink in one of the list items. However, this does not open the URL, but only closes the tab.
Why is this?
Is there something obvious I've done wrong?
Many thanks for any help.
Line 94 e.preventDefault();
means that the href doesnt trigger, hence not loading google.
Remove this and it works fine, see here
before binding tabs try to write something like
$('a.selector').click(function () { location.href = $(this).attr('href') })
In my opinion the line 94:
e.preventDefault();
prevents link opening
精彩评论