Euh... oke and in what way do i implement that? Can you give me a
example?
Thanks for the reply btw :-)
On Jan 7, 1:01 am, brian zijn.digi...@gmail.com wrote:
$target.css('...')
Or, better:
$target.addClass('SomeClassName');
var $target = $(this.hash);
$target.addClass('SomeClassName');
...
On Thu, Jan 7, 2010 at 10:02 AM, metalmini metalm...@gmail.com wrote:
Euh... oke and in what way do i implement that? Can you give me a
example?
Thanks for the reply btw :-)
On Jan 7, 1:01 am, brian zijn.digi...@gmail.com
Hi,
I am looking for some guidance on how to achieve a simple objective. I
have multiple DIV elements on a page, and within each DIV there
are 4 A elements. Within each A there is an IMG. My goal is to
apply a class to each of these IMG upon rendering the page.
the above post has a typo.
$('.description a:first-child img').addClass('icon_selected');
The first image is child of the first child (A element) of the DIV.
Maurício
Hello,
I am looking for some guidance on how to achieve a simple objective. I
have multiple DIV elements on a page, and within each DIV there
are 4 A
Hi,
I just realize that your code works fine.
It's verbose but works to me.
I am looking for some guidance on how to achieve a simple objective. I
have multiple DIV elements on a page, and within each DIV there
are 4 A elements. Within each A there is an IMG. My goal is to
apply a class to
Hi Mauricio,
$('.description a:first-child img').addClass('icon_selected');
the complete not-working example can be found here:
http://0.latest.gentlecolours.appspot.com/albums?album_name=Leigh_on_sea
Two things come to my mind: the statement is placed in the wrong place
or it clashes with
: jQuery (English) jquery-en@googlegroups.com
Enviada em: quinta-feira, 8 de janeiro de 2009 09:11
Assunto: [jQuery] Re: Highlighting the first element in multiple DIVS
Hi Mauricio,
$('.description a:first-child img').addClass('icon_selected');
the complete not-working example can be found
$('.description img:eq(0)').addClass('icon_selected') // add class to the
1st image element whitin div.description
Now it selects the first image of the first div only. I have updated
the test website with your change.
Martin
Hi Martin
Sorry my fault. :-(
Let's loop the div.description using the each() method.
$('.description') .each(function(){
$('img:eq(0)', this).addClass('icon_selected');
});
Maurício
...
Now it selects the first image of the first div only. I have updated
the test website with your
Those br /s make it all more difficult, why not use proper p
elements?
If you wrap the colour anchors in a DIV, you can remove both colour
and icon classes, and the script gets simpler:
div class=colours
a href=#FF
img src=images/icons/snowwhite.png alt=... /
/a
a href=#FF
Try using the .hover() method instead.
http://docs.jquery.com/Events/hover#overout
From the docs:
Additionally, checks are in place to see if the mouse is still
within the specified element itself (for example, an image inside of
a div), and if it is, it will continue to 'hover', and not
if they are all highlighted with the same color, surely you can't tell
if they both have the bg applied?
[EMAIL PROTECTED] wrote:
Hi,
I'm trying to highlights elements of the page on mouseover. I want to
highlight all td's h1's and p's when the mouse is over.
$(td, h1,
I just got it. I had .focus() instead of .select(). OK gotta end the long
day now.
So carry on folks. nothing to see here..
_
From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Michael E. Carluen
Sent: Thursday, July 19, 2007 1:05 AM
To:
13 matches
Mail list logo