ill notice, but still can make it work, im checking the html generated by the php, or make a new clean code for test.

:)

thx
----- Original Message ----- From: "Joel Birch" <[EMAIL PROTECTED]>
To: <jquery-en@googlegroups.com>
Sent: Tuesday, June 05, 2007 12:02 PM
Subject: [jQuery] Re: Problem getting first paragraph



On 06/06/2007, at 12:57 AM, Joel Birch wrote:

On 06/06/2007, at 12:48 AM, Sebastián V. Würtz wrote:
Right. but i need all the "first" paragraph of each "page", to execute an "each" function for each one :)

Sorry if I am misunderstanding, but as far as I can tell this should work:

 $('#book div.page p:first').each(function() {
/*do stuff with each first paragraph found within each .page div*/
});

For example, try this to test if we are getting the elements you  require:

$(document).ready(function() {
$('#book div.page p:first').each(function() {
this.css({'background-color':'yellow'});
});
)};

Good luck.

Joel.

Scratch that. For starters I forgot to wrap 'this' in $(). Also, it
only seems to get the the first para of the first .page element.

I'll try again.
__________ NOD32 2309 (20070605) Information __________

This message was checked by NOD32 antivirus system.
http://www.eset.com



--
Estoy usando la versión gratuita de SPAMfighter para usuarios privados.
Ha eliminado 2470 correos spam hasta la fecha.
Los usuarios de pago no tienen este mensaje en sus correos.
Obtenga SPAMfighter gratis aquí: http://www.spamfighter.com/les


Reply via email to