[jQuery] Selector help

2009-07-18 Thread Warfang
I'm pretty new to Javascript/ jQuery, so this is really bugging me. I'm trying to get the height of an h1 that is a sibling to this. The value for the variable h1Height, however, returned as null in the console in Firebug. Perplexed, I tried console.logging ('this'+'+h1') to see what it was inter

[jQuery] Selector help needed

2009-04-28 Thread Warfang
Here's my code: $(document).ready(function(){ $('#menulinks a').hover(function(){ setTimeout(function(){ $(this).stop().animate({ top : '40px', paddingTop : '40px'

[jQuery] Re: jQuery/ HTML help needed

2009-04-01 Thread Warfang
hange 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(500);  // fadeIn element with ID 'tab_1' > > > On Mar 31, 3:04 pm, Warfang wrote: > > > > 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.

[jQuery] Re: jQuery/ HTML help needed

2009-03-31 Thread Warfang
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.

[jQuery] Re: jQuery/ HTML help needed

2009-03-31 Thread Warfang
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

[jQuery] Re: jQuery/ HTML help needed

2009-03-31 Thread Warfang
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

[jQuery] jQuery/ HTML help needed

2009-03-31 Thread Warfang
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 slide 2 slide 3 slide 1

[jQuery] I can't figure out how to implement JQuery into my website

2009-03-01 Thread Warfang
What code do I need to put in my HTML header? I have already downloaded the JQuery code from JQuery's homepage to my computer, but where exactly do I put that? I'm using Webs.com to host now, so do I upload the code to my directory there? From there, how do I add new code from plugins? Sorry for