Try this:

$('div.sidebarToDo:last')

--Karl
_________________
Karl Swedberg
www.englishrules.com
www.learningjquery.com



On Feb 22, 2007, at 12:07 PM, <[EMAIL PROTECTED]> <[EMAIL PROTECTED]> wrote:

Hello,

I have a main div, with id= "todoList", and within it, a number of DIVs, all with classes "sidebarToDo". Let's say I have just added a DIV to the DOM ...

$('#todoList').append('<div class="sidebarToDo" width="100%">Hello</ div>');

How do I now get a reference to this last DIV with class "sidebarToDo"? Notice it doesn't have an ID, but it is the last one in the master todoList DIV.

Thanks so much.  This discussion group is excellent. - Dave


_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/

_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/

Reply via email to