You are viewing a plain text version of this content. The canonical link for it is here.
Posted to embperl@perl.apache.org by "goEbusiness.com Mail Lists" <ma...@goebusiness.com> on 2001/03/20 19:12:01 UTC

optDisableHtmlScan problems

Solaris 7 Sparc
Apache 1.3.14, Mod Perl 1.24
Embperl 1.3.1

Problem:
	Using [* *] delimiters, when I dynamically generate any select, or text boxes or whatever that Embperl should be replacing with formdata inputted values, if I first go to the page, it looks normal, but when I refresh the screen, the print OUT statements appear.  Even if you don't pass any data via a form or URL, as soon as you hit refresh, it messes up.

Example code:

[*
    my $TestVar = 'testvar' ;
*]

<table>
<tr>
    <td>Test</td>
    <td><input type="text" name="test" value="[* print OUT $TestVar ; *]"></td>
</tr>
</table>

Viewing the page source via the web browser first visit:

<table>
<tr>
    <td>Test</td>
    <td><input type="text" name="test" value="testvar"></td>
</tr>
</table>

After a refresh:

<table>
<tr>
    <td>Test</td>
    <td><input type="text" name="test" value="[* print OUT $TestVar ; *]">testvar"></td>
</tr>
</table>

Any ideas?

Thanks!

Bill


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


Re: Scoping typglobs in embperl

Posted by Gerald Richter <ri...@ecos.de>.
>
> At 5:39 AM +0100 3/21/01, Gerald Richter wrote:
> >[* *] are still experimental in Embperl 1.x. I know that they don't work
> >correctly in all situations. Please use [+ +] or [- -] instead.
>
> A thought related to [* *]
>
> I'm using DBIx::Recordset (very nice) in some of my embperl pages.
> Because it uses typglobs, I get concerned about scope, and having one
> part of page interfering with some other part, expecially if I'm
> including multiple embperl files in an EmbperlObject environment, so
> I do this:
>
> [* { local (*set); *]
> ...
> [- *set = somerecordsetcall -]
> ...
> do something with *set
> ...
> [* } *]
>
> a) Does this make sense, or am I causing myself unforeseen problems?

This should work, but I am not quite sure if Perl really cleans up the whole
DBIx::Recordset object in this way

> b) Might there be a better way to deal with this, by adding some new

Every single file have it's own namespace, so there can't be any
interferences between different files, also Embperl knows about
DBIx::Recordset and makes sure every DBIx::Recordset is closed and cleaned
up correctly at the end of the request.

If you want to cleanup a DBIx::Recordset in the middle of the page, you can
simple say

[- DBIx::Recordset::Undef ('set') -]


Gerald


-------------------------------------------------------------
Gerald Richter    ecos electronic communication services gmbh
Internetconnect * Webserver/-design/-datenbanken * Consulting

Post:       Tulpenstrasse 5         D-55276 Dienheim b. Mainz
E-Mail:     richter@ecos.de         Voice:    +49 6133 925131
WWW:        http://www.ecos.de      Fax:      +49 6133 925152
-------------------------------------------------------------




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


Scoping typglobs in embperl

Posted by Kee Hinckley <na...@somewhere.com>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

At 5:39 AM +0100 3/21/01, Gerald Richter wrote:
>[* *] are still experimental in Embperl 1.x. I know that they don't work
>correctly in all situations. Please use [+ +] or [- -] instead.

A thought related to [* *]

I'm using DBIx::Recordset (very nice) in some of my embperl pages. 
Because it uses typglobs, I get concerned about scope, and having one 
part of page interfering with some other part, expecially if I'm 
including multiple embperl files in an EmbperlObject environment, so 
I do this:

[* { local (*set); *]
...
[- *set = somerecordsetcall -]
...
do something with *set
...
[* } *]

a) Does this make sense, or am I causing myself unforeseen problems?
b) Might there be a better way to deal with this, by adding some new 
[$ construct for instance.  Something like:
	[$ local *foo $bar $]
...
	[$ endlocal $]
- -- 

Kee Hinckley - Somewhere.Com, LLC - Cyberspace Architects
Now Playing - Folk, Rock, odd stuff - http://www.somewhere.com/playlist.cgi

I'm not sure which upsets me more: that people are so unwilling to accept
responsibility for their own actions, or that they are so eager to regulate
everyone else's.

-----BEGIN PGP SIGNATURE-----
Version: PGPfreeware 7.0.3 for non-commercial use <http://www.pgp.com>

iQA/AwUBOrjDySZsPfdw+r2CEQJtNACeN3pUTx0MhEGT0LRPtV2lrx419S0AnRSR
BeDlLHNmHSFu2Jh8ufc1NG/6
=GEWR
-----END PGP SIGNATURE-----

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


Re: [* *] are experimental in 1.x! (was: optDisableHtmlScan problems)

Posted by Gerald Richter <ri...@ecos.de>.
>
> Problem:
> Using [* *] delimiters, when I dynamically generate any select, or text
boxes or whatever that Embperl should be replacing with formdata inputted
values, if I first go to the page, it looks normal, but when I refresh the
screen, the print OUT statements appear.  Even if you don't pass any data
via a form or URL, as soon as you hit refresh, it messes up.
>

[* *] are still experimental in Embperl 1.x. I know that they don't work
correctly in all situations. Please use [+ +] or [- -] instead.

[* *]  are working correctly in Embperl 2.0b1, but this first beta is not
ready for production yet. I hope to get out 2.0b2 soon, which should have
the main problems of 2.0b1 fixed.

Gerald
-------------------------------------------------------------
Gerald Richter    ecos electronic communication services gmbh
Internetconnect * Webserver/-design/-datenbanken * Consulting

Post:       Tulpenstrasse 5         D-55276 Dienheim b. Mainz
E-Mail:     richter@ecos.de         Voice:    +49 6133 925131
WWW:        http://www.ecos.de      Fax:      +49 6133 925152
-------------------------------------------------------------



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


Re: optDisableHtmlScan problems

Posted by "goEbusiness.com Mail Lists" <ma...@goebusiness.com>.
BTW, I also tried 

EMBPERL_OPTIONS 8392208

To disable the scanning of Select,Table,Input.

Bill

On Tue, 20 Mar 2001, goEbusiness.com Mail Lists wrote:

> Solaris 7 Sparc
> Apache 1.3.14, Mod Perl 1.24
> Embperl 1.3.1
> 
> Problem:
> 	Using [* *] delimiters, when I dynamically generate any select, or text boxes or whatever that Embperl should be replacing with formdata inputted values, if I first go to the page, it looks normal, but when I refresh the screen, the print OUT statements appear.  Even if you don't pass any data via a form or URL, as soon as you hit refresh, it messes up.
> 
> Example code:
> 
> [*
>     my $TestVar = 'testvar' ;
> *]
> 
> <table>
> <tr>
>     <td>Test</td>
>     <td><input type="text" name="test" value="[* print OUT $TestVar ; *]"></td>
> </tr>
> </table>
> 
> Viewing the page source via the web browser first visit:
> 
> <table>
> <tr>
>     <td>Test</td>
>     <td><input type="text" name="test" value="testvar"></td>
> </tr>
> </table>
> 
> After a refresh:
> 
> <table>
> <tr>
>     <td>Test</td>
>     <td><input type="text" name="test" value="[* print OUT $TestVar ; *]">testvar"></td>
> </tr>
> </table>
> 
> Any ideas?
> 
> Thanks!
> 
> Bill
> 
> 


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