Salve a tutti, il mio problema è il seguente:
Ho un campo checkbox, in una pagina ASP, oltre ad altri campi, io vorrei che quando cambio lo stato della checkbox in checked apparisse un campo, viceversa se metto lo stato su unchecker questo campo scompaia.
Vi posto il codice forse è più chiaro, e grazie a tutti che vorranno aiutarmi:
codice:<%if request.QueryString("IDAllenamento") = "" then%> <td class="label"><input <%If (CStr(rs("Allenamento")) = CStr("1")) Then Response.Write("checked=""checked""") : Response.Write("0")%> name="Allenamento" id="Allenamento" type="checkbox" title="ALLENAMENTO"> <script type="text/javascript"> var urlmenu = document.getElementById('Allenamento'); urlmenu.onchange = function() { window.open('gestione_campi.asp?ID=<%=ID%>&M=1&IDCategoria=<%=Kat%>&IDAllenamento=' + this.value,'_self'); }; </script> </td> <%else Allenamento = request.QueryString("IDAllenamento")%> <td class="label"><input <%If (CStr(Allenamento) = CStr("1")) Then Response.Write("checked=""checked""") : Response.Write("0")%> name="Allenamento" id="Allenamento" type="checkbox" title="ALLENAMENTO"></td> <%end if%> ' CAMPO CHE DEVE APPARIRE E SCOMPARIRE <%if rs("Allenamento") = "0" then%> <td class="label"><input type="text" name="Partita" id="Partita" required class="casellaTestoXLongRequired" size="30" value="<%=rs("Partita")%>"></td> <%elseif request.QueryString("IDAllenamento") = "on" then%> <td class="label"><input type="text" name="Partita" id="Partita" required class="casellaTestoXLongRequired" size="30" value="<%=rs("Partita")%>"></td> <%elseif Allenamento = "on" then%> <td class="label"><input type="text" name="Partita" id="Partita" required class="casellaTestoXLongRequired" size="30" value="<%=rs("Partita")%>"></td> <%elseif isnull(request.QueryString("IDAllenamento") = false) then%> <td class="label"><input type="text" name="Partita" id="Partita" required class="casellaTestoXLongRequired" size="30" value="<%=rs("Partita")%>"></td> <%else%> <td class="label"></td> <%end if%> :messner: