Reputation: 21
I have a form with dynamic fields..
When submit form, i have this:
Localhost:8000/mysite.com/jobs_form?job="Job1"&job="Job2"
And i cant get all of them in django with request.POST.get("job")
What can i do?
Upvotes: 2
Views: 37
Reputation: 477318
You can work with the .getlist(…)
method [Django-doc] of the request.GET
[Django-doc] querydict:
request.GET.getlist('job')
This will return a list with the two jobs, so ['Job1', 'Job2']
.
Upvotes: 1