Apache Mod-Python - Closed: (MODPYTHON-206) The attribute req.used_path_info

This is Interesting: Free IT Magazines  
Home > Archive > Apache Mod-Python > May 2007 > Closed: (MODPYTHON-206) The attribute req.used_path_info





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Closed: (MODPYTHON-206) The attribute req.used_path_info
Graham Dumpleton (JIRA)

2007-05-01, 7:12 am


[ https://issues.apache.org/jira/brow...ls:all-tabpanel ]

Graham Dumpleton closed MODPYTHON-206.
--------------------------------------


> The attribute req.used_path_info should be writable.
> ----------------------------------------------------
>
> Key: MODPYTHON-206
> URL: https://issues.apache.org/jira/browse/MODPYTHON-206
> Project: mod_python
> Issue Type: Improvement
> Components: core
> Affects Versions: 3.3
> Reporter: Graham Dumpleton
> Assigned To: Graham Dumpleton
> Fix For: 3.3
>
>
> At present, req.used_path_info is read only. This should instead be modifiable as well.
> This attribute gets set when you use the Apache AcceptPathInfo directive. You might use it for example as:
> <Files "mypaths.shtml">
> Options +Includes
> SetOutputFilter INCLUDES
> AcceptPathInfo On
> </Files>
> In this case use of AcceptPathInfo would be needed as the default-handler for serving up static files prohibits additional path info by default. Thus, if you want SSI files to be able to make use of additional path info, you have to enable it.
> In mod_python 3.3, the ability to register filters dynamically just for the current request means that SSI can be set up from within a fixuphandler using:
> def fixuphandler(req):
> if os.path.basename(req.filename) == 'mypaths.shtml':
> req.add_output_filter('INCLUDES')
> return apache.OK
> Without req.used_path_info being modifiable though, one can't do the equivalent to AcceptPathInfo from within the handler. Thus, req.used_path_info should be modifiable. The values this attribute needs to be set to are already specified in mod_python.ap

ache
> and thus only needs one line change to requestobject.c because value is an integer. The handler could then be written as:
> def fixuphandler(req):
> if os.path.basename(req.filename) == 'mypaths.shtml':
> req.add_output_filter('INCLUDES')
> req.used_path_info = apache.AP_REQ_ACCEPT_PATH_INFO
> return apache.OK


Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com