I'm a bit confused with all these attributes. I know "id" is used for css and js. But what about name and value?
<input type="checkbox" id="check" name="vehicle1" value="car">
Also, are there any other attributes which would help be in developing a website? (I'm still learning, and am not a developer yet)
CodePudding user response:
when you select this checkbox
Submitted Form Data Your input was received as:
vehicle1=Car
The server has processed your input and returned this answer. So, the checkbox named "vehicle1" having value "car".
CodePudding user response:
suppose u r using <input type='checkbox' id='check' name='vehicle' value='car'>
name attribute is use to identify uniquely.
when u insert data into database name attribute play important role.