Bring in the functionality for the spatial filter

spatialFilter.php: it is nessesary to check if the polygon is a proper
polygon. In the core.js it is impossible to creatie not proper polygons.
core.js: Creating the lat's and lon's as Strings