简体   繁体   中英

Python equivalent of php's virtual()

Do you know if there is a python equivalent of php's virtual() ?

My configuration is python, djanogo, mod_wsgi, apache

Trying to include a script that has only examples for php using the above include and also needs to be included in all website's pages.

Thanks

LE: I'm including a.cgi script

The only reference to this I see is

http://www.modpython.org/pipermail/mod_python/2004-January/014834.html

Which states In theroy you can use the Apache 2.x chain handlers feature, where more than one content handler can process the request. I say in theroy because I've read about it, but never tried it =) In theroy you can use the Apache 2.x chain handlers feature, where more than one content handler can process the request. I say in theroy because I've read about it, but never tried it =)

From the PHP Manual, virtual() is an Apache-specific function which is similar to <.--#include virtual...--> in mod_include. It performs an Apache sub-request. . . This function is only supported when PHP is installed as an Apache module. virtual() is an Apache-specific function which is similar to <.--#include virtual...--> in mod_include. It performs an Apache sub-request. . . This function is only supported when PHP is installed as an Apache module.

Here is the link for info about Apache Filters, which is what is meant by "chain handling":

http://httpd.apache.org/docs/2.2/filter.html

The document should be able to be processed by mod_include after it's output from mod_wsgi (or before, if that's what you want).

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM