Solved

Jquery Tabs plugin current version 1.9.3 - Make tab use a web page link

Posted on 2013-01-14
1
449 Views
Last Modified: 2013-01-14
I had this working in 1.7 version and now it is not.  I am hoping someone could help me out in how I get this done.

Basically I want to have all my tabs point to live web page links (not hidden panels)

below is how my old code works... Basically the Selected part of the tab is alwyas dynamically set.  Whatever that is set too the tab will match.  So I make the selected Tab href ="#<Name>" and then the other tabs href are actual links to webpages.

My links are valid I have cut and pasted them into abother browser window and they do work.

But every time I click on a tab which has a page link it now gives the url with "/undefined" added to the end.

So for example www.me.com/admin/undefined which isn't correct.

        <script type="text/javascript">
        $(function () {
        	// Tabs
            $("#tabs").tabs({
                select: function (event, ui) {
                    try {
                        window.location = $.data(ui.tab, 'href.tabs');
                    }
                    catch (err) {
                    //just ignore it.  For now..
                    }
                    return false;
                }
                , selected: 0
            });
 
        });
    </script>
<div id="tabs">
     <UL>
         <LI><a href="#details">Details</LI>
         <LI><a href="charges.aspx">Charges</LI>
         <LI><a href="History.aspx">History</LI>
     </UL>

</div>

Open in new window



How can I get this to work... I am under a crunch... otherwise I would go through and figure it out...

Any help is greatly appreciated :)
0
Comment
Question by:angelalaw
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 

Accepted Solution

by:
angelalaw earned 0 total points
ID: 38776978
For those who might be looking I figured it out...

window.location = $.data(ui.tab, 'href.tabs');

Changes to
window.location = ui.tab.href;

That will work, or at least it does now for me...
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction Since I wrote the original article about Handling Date and Time in PHP and MySQL several years ago, it seemed like now was a good time to update it for object-oriented PHP.  This article does that, replacing as much as possible the pr…
This article discusses how to create an extensible mechanism for linked drop downs.
The viewer will learn how to count occurrences of each item in an array.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.

710 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question