Added a method to escape dot in element id