javascript implementation for drawing placemark