Revision 3184
Added by Duane Costa over 17 years ago
lib/style/skins/default/include_advancedsearch.jsp | ||
---|---|---|
80 | 80 |
form.eastBound.value = ""; |
81 | 81 |
form.westBound.value = ""; |
82 | 82 |
|
83 |
if ((x_range != "-180.0 180.0") && (y_range != "-90.0 90.0")) {
|
|
83 |
if ((x_range != "-180.0 180.0") || (y_range != "-90.0 90.0")) {
|
|
84 | 84 |
form.northBound.value = y_hi; |
85 | 85 |
form.southBound.value = y_lo; |
86 | 86 |
form.eastBound.value = x_hi; |
Also available in: Unified diff
Fix bug in the Advanced Search form reported by Dave Balsiger at NTL. The bug occured only in one of the following two special cases:
(a) The user modifies longitude but leaves latitude at default values;
(b) The user modifies latitude but leaves longitude at default values.
There was a conditional AND that should have been coded as a conditional OR. The buggy logic was:
"If the user changes both latitude AND longitude, then use the spatial form values in the advanced search, otherwise ignore the spatial form values."
the correct logic is:
"If the user changes either the latitude OR longitude, then use the spatial form values in the advanced search, otherwise ignore the spatial form values."