The situation is a bit complicated. I don't see each image on page.
I have the first image on contact page. :( So .imagefield:eq(0) is not
a good solution

On Nov 12, 11:36 pm, George <[EMAIL PROTECTED]> wrote:
> You can do
> $('.imagefield:eq(0)') to select first image out of all 'imagefield'
>
> George
>
> On Nov 12, 4:33 pm, yo2lux <[EMAIL PROTECTED]> wrote:
>
>
>
>
>
> > I have some image on webpage:
>
> > <img class="imagefield" height="310" width="310" title="" alt="" src="/
> > sites/default/files/first.gif"/>
>
> > <img class="imagefield" height="310" width="310" title="" alt="" src="/
> > sites/default/files/second.gif"/>
>
> > <img class="imagefield" height="310" width="310" title="" alt="" src="/
> > sites/default/files/third.gif"/>
>
> > I need to set an event listener only on the first image.
> > - I think, $('.imagefield') is not a good solution, because set the
> > event listener on all image.
>
> > Is possible to set the event listener using the image name ? For
> > example: first.gif ?
>
> > Sorry I have a complicated situation, the html editing is not allowed
> > at all. Somehow I need to select the first image with jquery.
>
> > Thanks!

Reply via email to