I have a Django view like this:
def viewA(request):
if request.POST.get('Go'):
# Get all fields
all = {}
for key, values in request.POST.lists():
all[key]=values
print (all)
With this html:
<label>Numero de telefono</label>
<input type="text" name="phone" autocomplete="off"/>
<input type="submit" name="Go" value="Send">
When i click 'Go' button, i get "all" dict with the phone value inside. Ok.
My problem is that i have another view where i create input elements with a template like this:
<div>
{% for table, campos in tables.items %}
<div class="taable">
<label>{{table}}</label>
{% for campo in campos %}
<div class="caampo">
<input type="text" value="{{campo}}" disabled name="{{table}}:{{campo}}"/>
<select>
<option>Varchar</option>
<option>Int</option>
...
In this case, when i click 'Go' button don't retrieve the data for this elements created dynamically with django template. How can I get this?
Thanks!