- var marker = L.marker([0, 0], {icon: getUserIcon()});
-
- function submitSearch(e) {
- e.preventDefault();
-
- var bounds = map.getBounds();
-
- $("#sidebar_content").load($(this).attr("action"), {
- query: $("#query").val(),
- zoom: map.getZoom(),
- minlon: bounds.getWest(),
- minlat: bounds.getSouth(),
- maxlon: bounds.getEast(),
- maxlat: bounds.getNorth()
- });
-
- $("#sidebar").one("closed", function () {
- map.removeLayer(marker);
- map.removeObject();
- });
- }
-