perl-embperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Luiz Fernando B. Ribeiro" <l...@engenhosolucoes.com.br>
Subject Re: $escmode
Date Fri, 11 Mar 2005 20:13:11 GMT
On Fri, 11 Mar 2005 08:05:02 -0800, Daniel <embperl@7thfire.com> wrote:

>
> Hi all,
>
> I seem to have some problems when it comes to $escmode, and I'm probably
> not understanding this variable correctly.
>
> { local $escmode=0; print OUT "<b>sometext</b>"; }
>
> I thought the above code would actually print sometext in bold, however,
> no matter the escape mode, I seem to get the tags stripped out. How can
> I preserve the tags? I had it working in one instance, but I'm doing
> something like
>
> $str = "<"; $str .= "b>"; .. etc for it to work.
>
> thanks,
>
> Daniel

Inside [- -] tags you will have to escape \< the openning brackects of the  
html tags or set optRawInput as Gerald sugested.

Use $escmode for things like these:
[!
sub my_select {
	return qq|\<select name="test">...\</select>|;
}
!]

<html>
...
<p>Test: [+ local $escmode=0; my_select() +]</p>


-- 
Luiz Fernando B. Ribeiro
Engenho Soluções para a Internet
+55 11 6959-7610

---------------------------------------------------------------------
To unsubscribe, e-mail: embperl-unsubscribe@perl.apache.org
For additional commands, e-mail: embperl-help@perl.apache.org


Mime
View raw message