// ********************************************
// **        Flashmaps DB Mapper 1.1         **
// **      JavaScript Custom Functions       **
// ********************************************
// ** Feel free to make any changes you need **
// **      to fit your requirements.         **
// ********************************************
// **      (c)2006 Flashmaps Geospatial      **
// **        http://www.flashmaps.com        **
// ********************************************


// ********************************************
// **  Functions called from the map, events **
// ********************************************

// The visitor placed the mouse over a POI
function fmCustomPOIOnRollOver(fmPOIID) {}

// The visitor moved the mouse out of a POI
function fmCustomPOIOnRollOut(fmPOIID) {}

// The visitor clicked on a POI
function fmCustomPOIOnRelease(strEvent,fmPOIID) {
    // Highlight a POI inside the map
	fmPOIHighlight(fmPOIID, 'radiant');
}

// The map is ready to receive commands
function fmCustomMapIsReady() {}

// A set of POIs has been loaded
function fmCustomPOIURLLoaded(strPOIsURL, iPOIsNumber) {}

// ********************************************
// **  Functions to send commands to the map **
// ********************************************

// Highlight a POI
function fmCustomPOIHighlight(fmPOIID) {
	// Highlight a POI inside the map
	fmPOIHighlight(fmPOIID, 'radiant');
}

// Unhighlight a POI
function fmCustomPOIUnhighlight(fmPOIID) {
	// Unhighlight a POI inside the map
	fmPOIUnhighlight(fmPOIID);
}

// Highlight and focus on a POI
function fmCustomPOIHighlightAndFocusOn(fmPOIID, strMapScale, strMethod){
	// Focus and highlight on a POI inside the map
	fmPOIHighlightAndFocusOn(fmPOIID, strMapScale, 'radiant');
	fmPOIRemoveAll();
	fmPOILoadURL('info/restaurant_parking_pois.asp?poiid=' + fmPOIID);
	
	
}
// Highlight and focus on a POI
function fmNightlifeHighlightAndFocusOn(fmPOIID, strMapScale, strMethod){
	// Focus and highlight on a POI inside the map
	fmPOIHighlightAndFocusOn(fmPOIID, strMapScale, 'radiant');
	fmPOIRemoveAll();
	fmPOILoadURL('info/nightlife_parking_pois.asp?poiid=' + fmPOIID);
	
	
}
// Highlight and focus on a POI
function fmArtsHighlightAndFocusOn(fmPOIID, strMapScale, strMethod){
	// Focus and highlight on a POI inside the map
	fmPOIHighlightAndFocusOn(fmPOIID, strMapScale, 'radiant');
	fmPOIRemoveAll();
	fmPOILoadURL('info/culturalarts_parking_pois.asp?poiid=' + fmPOIID);
	
	
}
// Highlight and focus on a POI
function fmShoppingHighlightAndFocusOn(fmPOIID, strMapScale, strMethod){
	// Focus and highlight on a POI inside the map
	fmPOIHighlightAndFocusOn(fmPOIID, strMapScale, 'radiant');
	fmPOIRemoveAll();
	fmPOILoadURL('info/shopping_parking_pois.asp?poiid=' + fmPOIID);
	
	
}
// The visitor clicked on a Restaurant POI
function fmCustomRestaurantOnRelease(strEvent,fmPOIID) {
    // Highlight a POI inside the map
	fmPOIHighlightAndFocusOn(fmPOIID, '3000', 'radiant');
	fmPOIRemoveAll();
	fmPOILoadURL('info/restaurant_parking_pois.asp?poiid=' + fmPOIID);
}
// The visitor clicked on a Nightlife POI
function fmCustomNightlifeOnRelease(strEvent,fmPOIID) {
    // Highlight a POI inside the map
	fmPOIHighlightAndFocusOn(fmPOIID, '3000', 'radiant');
	fmPOIRemoveAll();
	fmPOILoadURL('info/nightlife_parking_pois.asp?poiid=' + fmPOIID);
}
// The visitor clicked on a Cultural Arts POI
function fmCustomArtsOnRelease(strEvent,fmPOIID) {
    // Highlight a POI inside the map
	fmPOIHighlightAndFocusOn(fmPOIID, '3000', 'radiant');
	fmPOIRemoveAll();
	fmPOILoadURL('info/culturalarts_parking_pois.asp?poiid=' + fmPOIID);
}
// The visitor clicked on a Shopping POI
function fmCustomShoppingOnRelease(strEvent,fmPOIID) {
    // Highlight a POI inside the map
	fmPOIHighlightAndFocusOn(fmPOIID, '3000', 'radiant');
	fmPOIRemoveAll();
	fmPOILoadURL('info/shopping_parking_pois.asp?poiid=' + fmPOIID);
}

function fmCustomParkingSearch(slat,slng) {
   
   fmFocusOnLatLon (slat,lng,'6000');
   fmPOIRemoveAll();
   fmPOILoadURL('info/search_pois.asp?latlng=' + slat + ',' + slng);
   
}