Is it valid to put a period in the "name" attribute of a HTML5 input?

html

Solution

Yes, it's valid.

But you will make things difficult for yourself if you need to access them via JS or CSS in particular. Again, it can be done, but it will make things difficult.

My advice is to use a hyphen instead.

Problem

Possible Duplicate: What are valid values for the id attribute in HTML? valid value for name attribute in html It is valid to name a HTML5 input with a string containing a period? ``` <input type="text" name="article.title" value="The title"/> ```

Original source

Related problems