@Elmar, there's nothing wrong with your jQuery; there is with
Joseph's: creating a closing LI won't work :(

Could you show where in your script you're trying to append the LI?

On Mar 10, 4:03 pm, Joseph Le Brech <jlebr...@hotmail.com> wrote:
> $("</li>").appendTo("#myList").html("Please show up");
>
> the one you used those should also work tho.
>
>
>
> > Date: Tue, 10 Mar 2009 14:18:57 -0700
> > Subject: [jQuery] add <li> to <ul>
> > From: elsch...@googlemail.com
> > To: jquery-en@googlegroups.com
>
> > Hi there,
> > I am probably trying the most basic example and failed in my attemps
> > so far. I would like to add new <li>´s to an existing <ul> with
> > jQuery. What I am trying to do:
>
> > in my script:
> > ...
> > $('#myList').append('<li>pleeeeease show up</li>');
> > ...
>
> > in my HTML:
> > ...
> > <ul id="myList" title="someTitle" selected="true">
> >         <li><a href="#internalLink">existing link</a></li>
> > </ul>
> > ...
>
> > But although I ask really nicely, the new li will never show up. The
> > "home" ul is found correctly by jQuery and I can output it´s contents.
>
> > What am I doing wrong?
> > Thanks a lot!
>
> _________________________________________________________________
> Twice the fun—Share photos while you chat with Windows Live Messenger. Learn 
> more.http://www.microsoft.com/uk/windows/windowslive/products/messenger.aspx

Reply via email to