Hi Doug,

> From within one request, I'm trying to Execute() an HTML 
> template from 
> another part of the application.  That template is dependent 
> on App object 
> methods defined in the _app.pl that is in the same directory 
> as the HTML 
> template.  However, the Execute() seems to use the Req and 
> App objects from 
> the calling context.  That App object does not have the 
> appropriate methods 
> defined, and I'd prefer not to have to copy them there, of 
> find some other 
> way to share them between the two App objects.
> 
> Does anyone have any ideas on how to make this Execute() 
> behave as what I 
> would call a 'first class request'?  In other words, get it 
> to load and use 
> the _app.pl that is associated with the target HTML template?

Haven't used it recently but the subrequest process is probably what
you're after:

http://perl.apache.org/embperl/pod/intro/IntroEmbperl2.-page-8-.htm

"When running Embperl with Apache 2.0 there are some extented
possibilities. While Apache 1.x has send all it's ouput directly to the
browser, Apache 2.0 introduces a concept of filters, which allows to
process the output of any Apache handler through a chain of filters.
Embperl can use this to embed any output that Apache can generate as a
Embperl::Object component, just like it is any native Embperl page. This
can be done by using the subreq parameter:

    [- Execute ({subreq=>'/cgi-bin/script.cgi'}) -]

The above code includes the output of a cgi script into a page."

Cheers,

Andrew


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

Reply via email to