Question: ```
jQuery("input[name=a.b.c]")

```

Executing this line using jQuery 1.10.2 or 1.9.1 results in the message:

"Syntax error, unrecognized expression: input:hidden[name=a.b.c]".

**I understand the core problem** which is that the dots are not escaped or quoted out. This would work:

```
jQuery("input[name='a.b.c']")

```

The constraint is that I do not have the ability to change the line of code with the bad selector. That line is produced by the website (which I don't own) and they don't give me the ability to change that. 

However, they do allow me to add arbitrary JS files to the header of the page (which means I can use a different jQuery version or even edit the jQuery file). My question is whether anyone knows another way around this so that jQuery can cope without the quotes since I cannot change the bad code.

For those saying that I can just change the name, this doesn't help because the JS still throws an error because changing the name of the element doesn't fix the bad selector.

Thanks

Answer: 
The proper way of executing this selector is:

```
jQuery('input[name="a.b.c"]')

```

Obviously you need to edit the algorithm that creates this line, there's no way jquery will accept an invalid selector.
Why don't you change the name attribute yourself?

```
var el = $("input"); 
el.attr("name", el.attr("name").replace(/[\d\.]+/g, "")); 
console.log(el.attr("name"));

```

Then change it back if you need to. jsFiddle [here](http://jsfiddle.net/qksmG/)