<div> is not inserted previous but upper
$('myInput').up('div');
You're right, striptags is a string extension.. so final code would be
alert($('myInput').up('div').innerHTML.stripTags());
On 13 okt, 11:47, DrBenway <[EMAIL PROTECTED]> wrote:
> I'm a little confussed about striptags.
>
> expl:
> <div>
> <input type='text' name='myinput' /> some text
> </div>
>
> I was hoping that alert($('myinput').previous('div').stiptags());
> would give me the content of the div without the input tag. Yet I get
> undefined.
> My guess is that striptags needs a string and my code doesn't return a
> string.
> Anyone out there who can enlighten me plz?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Prototype & script.aculo.us" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~----------~----~----~----~------~----~------~--~---