Created
May 25, 2012 08:19
-
-
Save witsch/2786593 to your computer and use it in GitHub Desktop.
lookup and render a given path from inside a view etc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from tribaspace.router import Router | |
path = '/foo/bar' | |
newreq = Request.blank(path=path, base_url=request.application_url) | |
newreq.registry = registry | |
markup = Router(registry).handle_request(newreq) | |
print markup.body |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment