Skip to main content

Search and Top Navigation

#7721 closed bug (notabug)

Opened September 15, 2011 09:53PM UTC

Closed September 15, 2011 11:43PM UTC

3.6 ...follow a tab's URL instead of loading its content via ajax

Reported by: spindlegoose Owned by:
Priority: minor Milestone: 1.9.0
Component: ui.tabs Version: 1.8.16
Keywords: Cc:
Blocked by: Blocking:
Description

I have two asp.net pages and I am using the tabs widget to navigate to the page but when I click on tab to go to the other page it calls it via ajax first then redirects to the page instead of going straight to the page.

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Test1.aspx.cs" Inherits="JqueryTabs.Test1" %>

<!DOCTYPE html PUBLIC "-W3CDTD XHTML 1.0 TransitionalEN" "http:www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head runat="server">

<title></title>

<link type="text/css" href="css/south-street/jquery-ui-1.8.16.custom.css" rel="stylesheet" />

<script type="text/javascript" src="js/jquery-1.6.2.min.js"></script>

<%--<script type="text/javascript" src="js/jquery-ui-1.8.16.custom.min.js"></script>--%>

<script type="text/javascript" src="js/jquery.ui.core.js"></script>

<script type="text/javascript" src="js/jquery.ui.tabs.js"></script>

<script type="text/javascript" src="js/jquery.cookie.js"></script>

<script type="text/javascript">

$(function () {

var tab_cookie_id = parseInt($.cookie("tab_cookie_2")) || 0;

Tabs

$('#tabs').tabs({

selected: tab_cookie_id,

select: function (event, ui) {

$("div.ui-tabs-panel").html("");

var url = $.data(ui.tab, "load.tabs");

if (url) {

$.cookie("tab_cookie_2", ui.index);

location.href = url;

}

}

});

});

$("div.ui-tabs-panel").html("");

</script>

</head>

<body>

<form id="form1" runat="server">

<div id="tabs">

<ul>

<li><a href="#local" id="Index" runat="server">Test 1</a></li>

<li><a href="Test2.aspx" id="Index2" runat="server">Test 2</a></li>

</ul>

<div id="local">

</div>

</div>

</form>

</body>

</html>

Attachments (0)
Change History (1)

Changed September 15, 2011 11:43PM UTC by rdworth comment:1

_comment0: You're not returning false like the FAQ tells you too. Also, please read the red notice box and do not dump code into a ticket.1316164444279327
resolution: → invalid
status: newclosed

You're not returning false like the FAQ tells you to. Also, please read the red notice box and do not dump code into a ticket.