[jQuery] Re: Problem with jquery tabs on live site

2010-01-11 Thread MorningZ
it can be easier than that, not so many variables to worry about :) right before $("#relatedTabs").tabs(); put $("#relatedTabs > ul a").attr("href", function() { if ($(this).attr("href").indexOf("#") > -1) { return "#" + $ (this).attr("href").split("#")[1]; } else { $(this).attr("href");

[jQuery] Re: Problem with jquery tabs on live site

2010-01-11 Thread Coxy
tabLinks= $('#relatedTabBar li a'); numOfTabs = tabLinks.length; for (index = 0; index < numOfTabs; index ++) { oldAnchor = $(tabLinks[index]).attr('href'); hashPos = oldAnchor.indexOf('#'); newAnchor = oldAnchor.substr(hashPos); $(

[jQuery] Re: Problem with jquery tabs on live site

2010-01-11 Thread Coxy
Thanks all, I have my problem solved. My CMS (TYPO3) was set to prefix local anchors (needed for the URL re-writing extension realurl) and this was changing the href's by adding a whole url. Since I can't turn of this function without switching of realurl I just alter the anchors before calling ta

[jQuery] Re: Problem with jquery tabs on live site

2010-01-11 Thread Coxy
In the included js (initialise.js): $(document).ready(function(){ ... // Code snipped // Related Tabs on single view $("#relatedTabs").tabs(); });

Re: [jQuery] Re: Problem with jquery tabs on live site

2010-01-11 Thread Charlie
when you put an actual url into tabs href it treats them as ajax tabs. If you aren't using AJAX in them remove the url within the href and replace with href="" Coxy wrote: No I'm not, and in my static mock-up everything was ok. It does this on the live site, and I want to find out why. Do

[jQuery] Re: Problem with jquery tabs on live site

2010-01-11 Thread MorningZ
yes, change the tags in the code above as shown... by putting a URL there you are telling the tabs plugin "go get this via AJAX request" See: http://jqueryui.com/demos/tabs/#ajax - Fetch external content via Ajax for the tabs by set

[jQuery] Re: Problem with jquery tabs on live site

2010-01-11 Thread MorningZ
yes, change the tags in the code above as shown... but putting a URL there you are telling the tabs plugin "go get this via AJAX request" On Jan 11, 11:43 am, Coxy wrote: > No I'm not, and in my static mock-up everything was ok. It does this > on the live site, and I want to find out why. Do yo

[jQuery] Re: Problem with jquery tabs on live site

2010-01-11 Thread Coxy
No I'm not, and in my static mock-up everything was ok. It does this on the live site, and I want to find out why. Do you know how to stop it?

[jQuery] Re: Problem with jquery tabs on live site

2010-01-11 Thread MorningZ
Are you looking to make an AJAX request to load the tab? i don't think you are considering your markup... change Related Articles Files Links to Related Articles Files L

[jQuery] Re: Problem with jquery tabs on live site

2010-01-11 Thread Coxy
$(document).ready(function(){ ... // Related Tabs on single view $("#relatedTabs").tabs(); }); It's in an external js: initialise.js

[jQuery] Re: Problem with jquery tabs on live site

2010-01-11 Thread Šime Vidas
I'm having a hard time finding the jQuery code that gets executed when you click on a tab...

[jQuery] Re: Problem with jquery tabs on live site

2010-01-11 Thread Coxy
Sorry, I wasn't sure if one was needed. Here is an example: http://krautspotter.bungert.co.uk/article/goerlitzer-park.html This loading of the whole page never happened with the static mock-up. Also jquery seems to have created it's own tabs. I never called them hrefs like #ui-tabs-22

[jQuery] Re: Problem with jquery tabs on live site

2010-01-11 Thread Šime Vidas
Have you considered giving us the link to the live site?