Re: Parsing the arguments in HTTP GET

2009-05-19 Thread Andrew Ingram
I've used the forms framework with GET (I'm using it for a search form and a 'q' parameter), but it never occurred to me to use it to validate non-form parameters. Thanks! - Andrew Ingram 2009/5/19 Russell Keith-Magee : > > On Tue, May 19, 2009 at 10:38 PM, Andrew

Re: Parsing the arguments in HTTP GET

2009-05-19 Thread Russell Keith-Magee
On Tue, May 19, 2009 at 10:38 PM, Andrew Ingram wrote: > > This is the only real way to do this with Django, though I do wish > there was a core Django way to validate GET params, ie which ones are > allowed and what format they should be. You mean, something like the

Re: Parsing the arguments in HTTP GET

2009-05-19 Thread Andrew Ingram
equest.GET['ui'] > > or you can default it by doing: >  ui=request.GET.get('ui','defaultvalue') > > > W > > -Original Message- > From: django-users@googlegroups.com > [mailto:django-us...@googlegroups.com] On Behalf Of MohanParthasarathy > Sent: Friday,

RE: Parsing the arguments in HTTP GET

2009-05-19 Thread Will Matos
: Parsing the arguments in HTTP GET Hi, I am very new to django. I am following along the tutorial. But I want to be able to parse the URL which has the following form: http://example.com/data/?ui=2=1#label=/fetch >From what I can tell, i can't match the whole thing using the url pattern

Re: Parsing the arguments in HTTP GET

2009-05-16 Thread Michael
> > On 15 May 2009, at 23:56, MohanParthasarathy wrote: > > > > > Hi, > > > > I am very new to django. I am following along the tutorial. But I want > > to be able to parse the URL which has the following form: > > > > http://example.com/data/?ui=2=1#label=/fetch > > > > From what I can tell,

Re: Parsing the arguments in HTTP GET

2009-05-16 Thread Vladimir Prudnikov
Do you want it to simply parse, or you want to add it into urlconf? If you want to just parse - use urlparse module http://docs.python.org/library/urlparse.html if you want to add it into the url config - simply handle 'data/' and the rest data you will get from GET data through request.GET

Re: Parsing the arguments in HTTP GET

2009-05-15 Thread Mohan Parthasarathy
On Fri, May 15, 2009 at 3:58 PM, Antoni Aloy wrote: > > 2009/5/15 MohanParthasarathy : > > > > Hi, > > > > I am very new to django. I am following along the tutorial. But I want > > to be able to parse the URL which has the following form: > > > >

Re: Parsing the arguments in HTTP GET

2009-05-15 Thread Mohan Parthasarathy
On Fri, May 15, 2009 at 4:39 PM, Tom Evans wrote: > > On Fri, 2009-05-15 at 14:56 -0700, MohanParthasarathy wrote: > > Hi, > > > > I am very new to django. I am following along the tutorial. But I want > > to be able to parse the URL which has the following form: > > >

Re: Parsing the arguments in HTTP GET

2009-05-15 Thread Tom Evans
On Fri, 2009-05-15 at 14:56 -0700, MohanParthasarathy wrote: > Hi, > > I am very new to django. I am following along the tutorial. But I want > to be able to parse the URL which has the following form: > > http://example.com/data/?ui=2=1#label=/fetch > > From what I can tell, i can't match

Re: Parsing the arguments in HTTP GET

2009-05-15 Thread Antoni Aloy
2009/5/15 MohanParthasarathy : > > Hi, > > I am very new to django. I am following along the tutorial. But I want > to be able to parse the URL which has the following form: > > http://example.com/data/?ui=2=1#label=/fetch > > From what I can tell, i can't match the whole

Parsing the arguments in HTTP GET

2009-05-15 Thread MohanParthasarathy
Hi, I am very new to django. I am following along the tutorial. But I want to be able to parse the URL which has the following form: http://example.com/data/?ui=2=1#label=/fetch >From what I can tell, i can't match the whole thing using the url pattern. I can parse up till