Ha! I looked at your post too fast, and didn't notice that it was pure
Javascript. Sorry. I'll try it and see.

The way I currently have it will not work with javascript turned off
either. I'm doing it this way only because the client is requiring the
user to have Javascript enabled to use the site (it's a backend system
for very specific clients). They want to add all sorts of animations
and effects like everyone wants to do once they see JQuery animations
in action.

On Mar 25, 12:14 pm, Martijn Houtman <martijn.hout...@gmail.com>
wrote:
> On Mar 25, 2009, at 5:04 PM, Shane Riley wrote:
>
> > Thanks for the article link, but your proposed change isn't valid
> > JQuery, is it? My exact jQuery code to read in the value looks like
> > this:
> > pageID = $(this).attr("href");
> > Adding what you suggested to make it $(this)[0].attr("href") will not
> > do anything apart from force the link to be followed.
>
> Well, no. I suggested using:
>
> pageID = $(this)[0].attr;
>
> This is plain JavaScript, rather than using jQuery's attr() function.  
> As the article suggests, this works cross-browser.
>
> > I think I'm going to have to move the contents of href to rel instead.
>
> Well, you could, but I wouldn't; this is not what the rel attribute  
> is meant for. Besides, it would break the anchor when JavaScript is  
> turned off.
>
> Regards,
> --
> Martijn.

Reply via email to