You are viewing a plain text version of this content. The canonical link for it is here.
Posted to embperl@perl.apache.org by Kee Hinckley <na...@somewhere.com> on 2000/03/20 17:02:37 UTC
Is there a way to turn off *all* processing in an Execute?
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
I'm using EmbperlObject and I want to Execute an HTML file and have
it automatically looked up in the search hierarchy. However I don't
want any directives in that file processed. In fact, I'd like it to
be possible that it's not even an HTML file, it might be a .jpg.
Obviously I could just go and do the search myself, but I'd rather
use the builtin rules.
- --
Kee Hinckley - Somewhere Consulting Group - Cyberspace Architects(rm)
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 6.5.2 for non-commercial use <http://www.pgp.com>
iQA/AwUBONZMCCZsPfdw+r2CEQJplQCgws/ERirf7BQg/szzqm9GfZcufXsAoOFd
XIpGHLhMC4Qob6xaxlgdesSC
=V7Ui
-----END PGP SIGNATURE-----
Re: Apache mod_perl gets blinded (@INC)
Posted by Gerald Richter <ri...@ecos.de>.
Hi!
>
> Does anubody know about strange behaviour, when modperl+Apache+Solaris
> gets just like blinded about perl's @INC path. modperl reports that it
> cannot find module Something.pm, gives its @INC path - which is completely
> correct. BUT, the module Something.pm complained about lies peacefully in
> declared @INC path. And is accessible. Problem disappear after Apache
> restarts. And appears again for some time.
>
>
Do you modify the normal @INC in any way (e.g. use lib etc.) ?
You could send us the exact error message, along with the abolute path where
the module lives ?
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
Apache mod_perl gets blinded (@INC)
Posted by Neeme Vool <ne...@eenet.ee>.
Hi!
Does anubody know about strange behaviour, when modperl+Apache+Solaris
gets just like blinded about perl's @INC path. modperl reports that it
cannot find module Something.pm, gives its @INC path - which is completely
correct. BUT, the module Something.pm complained about lies peacefully in
declared @INC path. And is accessible. Problem disappear after Apache
restarts. And appears again for some time.
Neeme Vool
Tel: +372 7 302 113
Fax: +372 7 302 111
E-mail: Neeme.Vool@eenet.ee
On Wed, 21 Mar 2001, Gerald Richter wrote:
> >
> > If not a call to get the path to an EmbperlObject located object, how
> > about a flag on Execute to tell it to process *nothing*? I have a
> > problem now that I'm processing files uploaded to the web site, and I
> > definitely do *not* want them to have Perl code in them. I'm working
> > around it now by finding the file myself and just printing it out,
> > but it would be nice if I could just call Execute on them.
>
> I have just implemented this feature in the current developement version of
> Embperl 2.0, but unfortunately 2.0 is not ready for production right now :-(
>
> We can emulate at least the Text only syntax in Embperl 1.3, try the
> following patch:
>
> In Embperl.pm Line 941 change
>
> $rc = CleanCallExecuteReq ($r, $$req{'param'}) ;
>
> to
>
> if ($req -> {'syntax'} eq 'Text')
> {
> if (open FH, "<$Inputfile")
> {
> local $/ = undef ;
> print OUT <FH> ;
> close FH ;
> }
> else
> {
> $r -> logerror (rcFileOpenErr, $Inputfile) ;
> }
> }
> else
> {
> $rc = CleanCallExecuteReq ($r, $$req{'param'}) ;
> }
>
>
> Now you can inlcude your text files with
>
> Execute ({inputfile => '*', syntax => 'Text'}) ;
>
> Embperl 2.0 will allow not only Embperl and pure Text syntax, but you can
> define your own syntaxes. This will be available in the next beta and the
> above patch is compatible with 2.0.
>
> Let me know if this works for you
>
> 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
>
---------------------------------------------------------------------
To unsubscribe, e-mail: embperl-unsubscribe@perl.apache.org
For additional commands, e-mail: embperl-help@perl.apache.org
Re: Is there a way to turn off *all* processing in an Execute?
Posted by Gerald Richter <ri...@ecos.de>.
>
> If not a call to get the path to an EmbperlObject located object, how
> about a flag on Execute to tell it to process *nothing*? I have a
> problem now that I'm processing files uploaded to the web site, and I
> definitely do *not* want them to have Perl code in them. I'm working
> around it now by finding the file myself and just printing it out,
> but it would be nice if I could just call Execute on them.
I have just implemented this feature in the current developement version of
Embperl 2.0, but unfortunately 2.0 is not ready for production right now :-(
We can emulate at least the Text only syntax in Embperl 1.3, try the
following patch:
In Embperl.pm Line 941 change
$rc = CleanCallExecuteReq ($r, $$req{'param'}) ;
to
if ($req -> {'syntax'} eq 'Text')
{
if (open FH, "<$Inputfile")
{
local $/ = undef ;
print OUT <FH> ;
close FH ;
}
else
{
$r -> logerror (rcFileOpenErr, $Inputfile) ;
}
}
else
{
$rc = CleanCallExecuteReq ($r, $$req{'param'}) ;
}
Now you can inlcude your text files with
Execute ({inputfile => '*', syntax => 'Text'}) ;
Embperl 2.0 will allow not only Embperl and pure Text syntax, but you can
define your own syntaxes. This will be available in the next beta and the
above patch is compatible with 2.0.
Let me know if this works for you
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: Is there a way to turn off *all* processing in an Execute?
Posted by Kee Hinckley <na...@somewhere.com>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
At 10:05 AM +0100 3/22/00, Gerald Richter wrote:
> >
>> The problem is that I'm processing auto-generated HTML files. I can
>> modify them and escape all the [[ blocks, but it occurred to me that
>> I really didn't want any processing at all, so why bother with the
> > overhead. I guess what would do just fine is if EmbperlObject had a
>> call that, given a file, would give me a path to where it found it.
>>
>
>Such a call will come surly in one of the next releases, until then you need
>your escape workaround...
If not a call to get the path to an EmbperlObject located object, how
about a flag on Execute to tell it to process *nothing*? I have a
problem now that I'm processing files uploaded to the web site, and I
definitely do *not* want them to have Perl code in them. I'm working
around it now by finding the file myself and just printing it out,
but it would be nice if I could just call Execute on them.
- --
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/AwUBOreioSZsPfdw+r2CEQJOpQCgpZDw67rkKWvCW2kM+gixqXWEaAwAnjjl
4xhMANxEDhA9ACQVN2xoMN0T
=HwZJ
-----END PGP SIGNATURE-----
---------------------------------------------------------------------
To unsubscribe, e-mail: embperl-unsubscribe@perl.apache.org
For additional commands, e-mail: embperl-help@perl.apache.org
RE: Is there a way to turn off *all* processing in an Execute?
Posted by Gerald Richter <ri...@ecos.de>.
>
> The problem is that I'm processing auto-generated HTML files. I can
> modify them and escape all the [[ blocks, but it occurred to me that
> I really didn't want any processing at all, so why bother with the
> overhead. I guess what would do just fine is if EmbperlObject had a
> call that, given a file, would give me a path to where it found it.
>
Such a call will come surly in one of the next releases, until then you need
your escape workaround...
> BTW. Embperl states that all ['s should be escaped, howeverI note
> that it doesn't do anything with code like [foo]. Should I trust
> that to remain the case?
Yes, this will remain, you only have to escape Embperl special charaters
like [+ or [- and so on, but there might be more of them in the future, so
it will be more safe (and easier) to simply substitue all [ with [[
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 925151
WWW: http://www.ecos.de Fax: +49 6133 925152
-------------------------------------------------------------
RE: Is there a way to turn off *all* processing in an Execute?
Posted by Kee Hinckley <na...@somewhere.com>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
At 12:23 PM +0100 3/21/00, Gerald Richter wrote:
> > I'm using EmbperlObject and I want to Execute an HTML file and have
>> it automatically looked up in the search hierarchy. However I don't
>> want any directives in that file processed. In fact, I'd like it to
>> be possible that it's not even an HTML file, it might be a .jpg.
>> Obviously I could just go and do the search myself, but I'd rather
>> use the builtin rules.
>
>You can turn of the HTML processing with
>
>Execute ({inputfile => 'foo.xyz', options=>
>HTML::Embperl::optDisableHtmlScan}) ;
>
>but you cannot turn off the processing of [+/-/$ $/-/+] blocks. This will
>work for most ascii files, but the current version of Embperl does not work
>correctly with binary data (it stop processing when it finds a binary 0).
>The next version will be binary clean.
The problem is that I'm processing auto-generated HTML files. I can
modify them and escape all the [[ blocks, but it occurred to me that
I really didn't want any processing at all, so why bother with the
overhead. I guess what would do just fine is if EmbperlObject had a
call that, given a file, would give me a path to where it found it.
BTW. Embperl states that all ['s should be escaped, howeverI note
that it doesn't do anything with code like [foo]. Should I trust
that to remain the case?
- --
Kee Hinckley - Somewhere Consulting Group - Cyberspace Architects(rm)
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 6.5.2 for non-commercial use <http://www.pgp.com>
iQA/AwUBONe5qyZsPfdw+r2CEQKN/QCfb4IfREuyTKvRwq12pInBqnUNYXAAoJI6
wVgc0BMoJd5e/cdBQWMeDkjN
=SHQd
-----END PGP SIGNATURE-----
RE: Is there a way to turn off *all* processing in an Execute?
Posted by Gerald Richter <ri...@ecos.de>.
> I'm using EmbperlObject and I want to Execute an HTML file and have
> it automatically looked up in the search hierarchy. However I don't
> want any directives in that file processed. In fact, I'd like it to
> be possible that it's not even an HTML file, it might be a .jpg.
> Obviously I could just go and do the search myself, but I'd rather
> use the builtin rules.
You can turn of the HTML processing with
Execute ({inputfile => 'foo.xyz', options=>
HTML::Embperl::optDisableHtmlScan}) ;
but you cannot turn off the processing of [+/-/$ $/-/+] blocks. This will
work for most ascii files, but the current version of Embperl does not work
correctly with binary data (it stop processing when it finds a binary 0).
The next version will be binary clean.
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 925151
WWW: http://www.ecos.de Fax: +49 6133 925152
-------------------------------------------------------------