aboutsummaryrefslogtreecommitdiffstats
path: root/web/js.js
diff options
context:
space:
mode:
authormatthew <matthew>2007-07-19 14:00:51 +0000
committermatthew <matthew>2007-07-19 14:00:51 +0000
commit83ffacea2e30190d600c88f276e1173df63410c6 (patch)
tree059f1e42c26d0b0680bb486679e8ac239bc143cb /web/js.js
parent844cf9d7d9e3a6e9dd725aab2a87bcf2728ff061 (diff)
Fix IE id/name bug; only do it if button present.
Diffstat (limited to 'web/js.js')
-rw-r--r--web/js.js8
1 files changed, 5 insertions, 3 deletions
diff --git a/web/js.js b/web/js.js
index 89e2567f1..760a8896b 100644
--- a/web/js.js
+++ b/web/js.js
@@ -10,7 +10,7 @@
*/
YAHOO.util.Event.onContentReady('pc', function() {
- if (this.value == this.defaultValue) {
+ if (this.id && this.value == this.defaultValue) {
this.focus();
}
});
@@ -45,8 +45,10 @@ YAHOO.util.Event.onContentReady('map', function() {
YAHOO.util.Event.onContentReady('mapForm', function() {
this.onsubmit = function() {
- this.submit_problem.disabled = true;
- this.submit_map.value = 2;
+ if (this.submit_problem) {
+ this.submit_problem.disabled = true;
+ this.submit_map.value = 2;
+ }
this.x.value = x + 2;
this.y.value = y + 2;
return true;