Maybe try ('#mydiv > ul').text('') , or something like that....

On 31 Maj, 13:28, caroig <[EMAIL PROTECTED]> wrote:
> I have a div containing text and an unordered list. I was to clear the
> text from the div without affecting the ul.
> $('#mydiv').text() returns just the text string, while $
> ('#mydiv').text('') successfully clears the text but also removes the
> html.
>
> How  can I remove just the text?
>
> Thanks

Reply via email to