Re: Tag in textarea?

Russell Gold <[email protected]>
Newsgroups gmane.comp.web.httpunit.devel
Message-ID <[email protected]>
On Mar 29, 2006, at 12:28 PM, Xu Jia wrote:

> Hello,
>
> if i have following code in html file:
> <textarea name=ta>test<img src=a.jpg></textarea>
>
> with browser.getFormParameterValue("ta"), it returns only "test"  
> instead of "test<img src=a.jpg>"?
>
> I have checked, there is no difference between
> <textarea name=ta>test<img src=a.jpg></textarea>
> <textarea name=ta>test</textarea><img src=a.jpg>?
>
> How can I get the real value of the textarea?

The parser is being pedantic. Your HTML is not well-formed; it should  
be:

> <textarea name=ta>test&lt;img src=a.jpg&gt;</textarea>

I'm not sure that either parser supported by HttpUnit can return what  
you want.


-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.