i'm understand right now, thank you so much for your detail explaination ron
On Sun, May 15, 2011 at 2:08 PM, ron_m <ron.mco...@gmail.com> wrote: > In the core chapter of the book I found this: > > In the above example, both request.args[i] and request.args(i) can be used > to retrieve the i-th element of the request.args, but while the former > raises an exception if the list does not have such an index, the latter > returns None in this case. > > I would use request.args(0) and test for None if it is legal for the arg to > not to be there on some requests. Conversely, if arg 0 is always supposed to > be part of the request then request.args[0] would generate an exception and > a ticket indicating a failure condition when it is missing. > >