Changeset 926
- Timestamp:
- 01/12/06 12:42:46
- Files:
-
- trunk/cherrypy/__init__.py (modified) (2 diffs)
- trunk/cherrypy/_cphttptools.py (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/cherrypy/__init__.py
r910 r926 4 4 5 5 import datetime 6 import os.path 6 7 import sys 7 8 import types … … 101 102 logfunc(msg, context, severity) 102 103 104 def url(u): 105 return request.app_path + u trunk/cherrypy/_cphttptools.py
r917 r926 270 270 names = [name for name, candidate in objectTrail] 271 271 272 # Try to get app_path: 273 current_objectpath = objectpath 274 for i in xrange(len(objectTrail) - 1, -1, -1): 275 name, candidate = objectTrail[i] 276 if getattr(candidate, 'is_app_root', False): 277 cherrypy.request.app_path = current_objectpath 278 break 279 current_objectpath = os.path.dirname(current_objectpath) 280 272 281 # Try successive objects (reverse order) 273 282 mounted_app_roots = cherrypy.tree.mount_points.values()

