+ 1
What is the point of the name and value attributes?
Please help me! what is the point of the name and value attributes in <input type="radio" name="gender" value="male"/> male <br /> I feel like indicating that it is gender has nothing to do with it. and that the value="male" also has nothing to do with it because it is the "male" that is outside the > that displays the text.
5 ответов
+ 2
When you'll submit form data, names and values will form key-values for processing on server.
+ 2
name should be used so tht only one is selected from radio buttons having same name and value is used while retrieving the selected radio button value
+ 1
name is like a variable in php... and male in value gives its "value" and outside the tags is just for display... Example: name = animal value = dog... It is just like Var animal = dog
0
a bit confusing shaa
0
Bueno yo solo hablo español
Espero alguien que hable español vea esta respuesta