Final PHP. Javascript needs some work - the mavrkercluster is not working properly with the search.