This working fine for attribute values like:
$self->AddTag("input", ["id", "name", "type", "value"], undef(), undef(),
{ perlcode => q{
_ep_sa(%$n%, 'value', $epreq->Escape(%&'value%, 5));
}});
But I'm having a little trouble with textareas.
Given this input,
<textarea name="foo">test</textarea>
and
$self->AddTag("textarea", ["id", "name", "rows", "cols"], undef(), undef(),
{ perlcode => q{
print STDERR "|".XML::Embperl::DOM::Node::iChildsText(%$n%)."|\n";
_ep_rp(%$x%, $epreq->Escape(XML::Embperl::DOM::Node::iChildsText(%$n%), 5));
}});
I'd expect |test| in my logs. I'm getting ||. If I change "test" to something that actually warrants escaping, I will still get the original text, not the escaped text.
If I change it to
$self->AddTag("textarea", ["id", "name", "rows", "cols"], undef(), undef(),
{ perlcode => q{
print STDERR "|".XML::Embperl::DOM::Node::iChildsText(%$n%)."|\n";
_ep_rp(%$x%, $epreq->Escape("hello world", 5));
}});
I will actually get the following as embperl output.
<textarea name="foo">hello worldtest</textarea>
So I think I'm not understanding some of the functions or special variables here. Can anyone lend some help? Thanks
Running Embperl 2.2 on Apache 1.3.29.
Richard "Trey" Hyde Lead Software Engineer, CNET Channel [EMAIL PROTECTED] |