Added a polygon test and fixed a KML tag error.