I can't tell what you're doing wrong - if anything - but the following works perfectly for me (using v1.2.1)
<select id='app.id' name='fred'> <option value='11'>one</option> <option value='22' selected='selected'>two</option> </select> var t = $('#app\\.id').val(); // t is 22 syg6-2 wrote: > > > In the FAQ it says that if you have an element with a 'special > character' in it you must escape it. Fair enough. I have this select: > > <select id='app.id'> > <option>... > </select> > > When I try the following: > > $("select#app\\.id").val() > > I get null. These don't work either: > > $("#app\\.id").val() > $("#app.id").val() > $("select#app.id").val() > > What am I doing wrong? > > Thanks > Bob > > > -- View this message in context: http://www.nabble.com/val-function-for-select-with-%27special-character%27-not-working-tf4535342s15494.html#a12949720 Sent from the JQuery mailing list archive at Nabble.com.