In that case, you could do something like:

def places():
    lastname, firstname = request.args[0:2]

Then for a URL like /myapp/mycontroller/places/John/Doe, "John" would be in 
request.args[0] and "Doe" would be in request.args[1].

Anthony

On Tuesday, February 26, 2013 11:57:55 AM UTC-5, [email protected] wrote:
>
> Sorry, let me clarify and be more specific again. The framework I referred 
> to was Django, where their url dispatcher can create named groups like so:
>
> r'^places/(?P<lastname>\w+)/(?P<firstname>\w+)/$', 'misc.views.home'
>
>
> This url would be mapped to a function with the name given in the url:
>
>
> def home(request, lastname, firstname)
>
>    # Do something with name and return data to webpage
>
>
>
> I don't quite understand how web2py's routes.py would handle this.
>
>
>
>
>>>

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to