8

My html code is as below.

<div id="chatbox_dipesh.parmar" class="chatbox">
  //html markup which is validated
</div>

in above code dipesh.parmar div added dynamically.

And i am accessing it using following code.

$("#chatbox_"+chatboxtitle).show();

where chatboxtitle is dipesh.parmar but its not selecting div.

Does . is not a valid for ID.?

My jQuery is loaded and its not conflicting with other library and also wrapped it into $(function(){ }).

Thanks.

Charles
  • 50,943
  • 13
  • 104
  • 142
Dipesh Parmar
  • 27,090
  • 8
  • 61
  • 90

1 Answers1

11

Escape the dot.

See this: Direction

Community
  • 1
  • 1
Rob
  • 4,927
  • 12
  • 49
  • 54