Revision 3459
Added by ben leinfelder over 16 years ago
SaeonLogin.jspx | ||
---|---|---|
89 | 89 |
} |
90 | 90 |
if (!organizationScope.equals("%")) { |
91 | 91 |
</jsp:scriptlet> |
92 |
<jsp:expression>request.getParameter("organizationScope")</jsp:expression> |
|
92 |
<!-- set the map to use the correct scope --> |
|
93 |
<script type="text/javascript" > |
|
94 |
var dropDownTimer = null; |
|
95 |
|
|
96 |
//this syncs the map based on the input string location |
|
97 |
function setMapLocation(strLocation) { |
|
98 |
|
|
99 |
var mapFrameDocument = document.getElementById("mapFrame").contentDocument; |
|
100 |
|
|
101 |
//check if the dropdown is loaded in DOM |
|
102 |
if (mapFrameDocument.getElementsByName('locations').length == 0) { |
|
103 |
dropDownTimer = setTimeout("setMapLocation('" + strLocation + "')", 100); |
|
104 |
return false; |
|
105 |
} |
|
106 |
clearTimeout(dropDownTimer); |
|
107 |
|
|
108 |
var locationMenu = mapFrameDocument.getElementsByName('locations')[0]; |
|
109 |
//alert("locationMenu=" + locationMenu); |
|
110 |
var locationOptions = locationMenu.options; |
|
111 |
//alert("locationOptions=" + locationOptions); |
|
112 |
//loop through the options to find the correct location based on input string |
|
113 |
for (var i=0; i < locationOptions.length; i++) { |
|
114 |
if (locationOptions[i].text == strLocation) { |
|
115 |
//set as selected |
|
116 |
locationMenu.selectedIndex = i; |
|
117 |
break; |
|
118 |
} |
|
119 |
} |
|
120 |
//alert("Focusing on selected location: " + locationMenu.options[locationMenu.selectedIndex].text); |
|
121 |
|
|
122 |
//the onchange command from select object |
|
123 |
locationMenu.onchange(); |
|
124 |
//mapFrameDocument.config.objects.locationsSelect.setAoi(locationMenu.options[locationMenu.selectedIndex].value,'mainMap'); |
|
125 |
|
|
126 |
} |
|
127 |
|
|
128 |
//kick it off |
|
129 |
dropDownTimer = |
|
130 |
setTimeout( |
|
131 |
"setMapLocation('<jsp:expression>organizationScope</jsp:expression>')", |
|
132 |
100); |
|
133 |
|
|
134 |
</script> |
|
135 |
|
|
136 |
<jsp:expression>organizationScope</jsp:expression> |
|
93 | 137 |
<jsp:scriptlet> |
94 | 138 |
} |
95 | 139 |
else { |
... | ... | |
119 | 163 |
would locate any phrase with the word herbivore embedded within it). |
120 | 164 |
</p> |
121 | 165 |
<input name="anyfield" value="" type="text" size="14" /> |
166 |
<jsp:element name="input"> |
|
167 |
<jsp:attribute name="name">placekey</jsp:attribute> |
|
168 |
<jsp:attribute name="type">hidden</jsp:attribute> |
|
169 |
<jsp:attribute name="value"> |
|
170 |
<jsp:expression>organizationScope</jsp:expression> |
|
171 |
</jsp:attribute> |
|
172 |
</jsp:element> |
|
122 | 173 |
<input name="action" value="query" type="hidden" /> |
123 | 174 |
<input value="Search" type="submit" /> |
124 | 175 |
|
... | ... | |
129 | 180 |
<form name="browseform" method="post" action="../../../metacat" |
130 | 181 |
target="_top"> |
131 | 182 |
<jsp:include page="SimpleSearchMetacatPostFields.html" /> |
132 |
<input name="anyfield" type="hidden" value="%" />
|
|
183 |
<input name="anyfield" type="hidden" value="%" /> |
|
133 | 184 |
<jsp:element name="input"> |
185 |
<jsp:attribute name="name">placekey</jsp:attribute> |
|
186 |
<jsp:attribute name="type">hidden</jsp:attribute> |
|
187 |
<jsp:attribute name="value"> |
|
188 |
<jsp:expression>organizationScope</jsp:expression> |
|
189 |
</jsp:attribute> |
|
190 |
</jsp:element> |
|
191 |
<jsp:element name="input"> |
|
134 | 192 |
<jsp:attribute name="name">sessionid</jsp:attribute> |
135 | 193 |
<jsp:attribute name="type">hidden</jsp:attribute> |
136 | 194 |
<jsp:attribute name="value"> |
... | ... | |
285 | 343 |
|
286 | 344 |
<!-- Map here --> |
287 | 345 |
<br /> |
288 |
<h3>Southern Africa</h3>
|
|
346 |
<h3>Spatial Search</h3>
|
|
289 | 347 |
|
290 | 348 |
<!-- map frame --> |
291 | 349 |
<script language="JavaScript"> |
Also available in: Unified diff
added:
-zoom on map with named locations for quick spatial searching based on selected park name (hooray javascript!)
-narrow search by selected park name
-cursor tracking in lat/lon
-alpha sort for left nav
-reference to fgdc in footer copy