1. cherrypy
  2. CherryPy
Issue #1169 new

Dispatcher examples

space one
created an issue

the examples in http://docs.cherrypy.org/stable/concepts/dispatching.html#other-dispatchers are not really understandable:

how to use the regex mapping dispatcher ? what happens when i pass None to cherrypy.tree.mount as root? is it required if i use my own uri-dispatcher? can i use it for accessing my own application?

also what possibilites do i have with the RoutesDispatcher? (routes parameter can contain regex e.g. 'foo/{id:[0-9]}/bar') but will id be **kwarg['id'] in the controllerfunction then / how to access it? what happens with GET and POST data then? what kind of conditions can be applied? a list of methods is possible, can i also filter for a specific http header (content-type = r'*/*') ??

Another question: if i am using more than one application: will the other dispatcher need the whole uri or is it stripped out?

Comments (0)

  1. Log in to comment