// global variable var g = {}; g.baseURL = "http://gis.sandy.utah.gov/ArcGIS/rest/services/"; g.googleBaseURL = g.baseURL + "Public_Works/Google_Basemap/MapServer"; g.bwURL = g.baseURL + "Public_Works/BulkWasteAreas/MapServer"; g.vectorQueryURL = g.baseURL + "Public_Works/Vector_Basemap/MapServer/6"; g.locatorURL = g.baseURL + "Sandy_Address_Locator/GeocodeServer"; g.fldBW_DATE = "BW_DATE"; g.fldAREA_NUM = "AREA_NUM";
This has kept my code a little cleaner and has made it far easier to find the evil things during run-time with FireBug. My latest project with bulk waste data was my first attempt at global variable redemption.
No comments:
Post a Comment