Woah, thanks! It worked! I was bent on the idea that selectors had to
have quotation marks. I suppose (in this case at least) thats untrue.
Thank you.
On Mar 31, 11:14 pm, Ricardo wrote:
> Actually this is the perfect opportunity to put those href's into use:
>
>
> slide 1
> sli
Actually this is the perfect opportunity to put those href's into use:
slide 1
slide 2
slide 3
slide 1
slide 2
slide 3
The script:
$('#tab_links a').click(function(){
var activeTab = $(this).attr('href');
$(activeTab).fadeIn(500);
ret
You're making it more complicated than it really is.
Using something similar to Jonathan's method:
// Change your id to something like 'link_1', like here:
slide 1
var activeTabID = $(this).attr('id'); // -> link_1
var activeTab = activeTabID.split('_')[1]; // -> 1
$('#tab_'+activeTab).fadeIn
Could I do something like this?...
var activeTab = $(this).attr('id');
$(''#(activeTab)'').fadeIn(500);
Those are two single quotes by the way. That is what I would like to
accomplish.
Sorry for not explaining this well. In the first line, "(this)" is the
link that you click. The the id is used as a selector to select the
"tab" that relates to that link. What I'd like to do is something like
this:
var activeTab = [single quote here] $(this).attr("id") [single quote
here];
Is
ID's have to start with a letter like the validator and james said.
You didn't really explain why, you just showed a block of code.
I think I get what you're trying to do but you really shouldn't be
using IDs like that. ID's are a unique way to IDentify an element, not
to get tricky with linking
I'm not sure I understand what you're trying to do. Having the # and
single-quotes in the id is invalid. I'm not sure how having it there
is suppose to make things work.
Similar to jQuery UI Tabs, maybe you should consider putting "tab_1"
inside the 's 'title' attribute instead:
slide 1
If you r
Yes, but I explained why...
"I, though, used single quote marks so that it
worked with the second line of script that I showed you."
I just need to know what to put in the var line so that I can remove
those quotes.
On Mar 31, 7:49 pm, James wrote:
> slide 1
> is suppose to be:
> slide 1
slide 1
is suppose to be:
slide 1
On Mar 31, 1:36 pm, Warfang wrote:
> Alright, heres the situation: I'm creating a tabbed box with jQuery
> and with some HTML tricks. The code that I came up with works great
> but is considered invalid markup by W3 standards.
>
> HTML:
>
> slide 1
>
9 matches
Mail list logo