addNewFeature: function () {
userMgr.close();
-
function cancel() {
$(document).unbind("keydown");
Admin.reset()
}
});
- $("#newfeature_button").val("annuler");
+ $("#newfeature_button").val(SypStrings.Cancel);
$("#newfeature_button").unbind("click").click(cancel);
$("#instructions").text(SypStrings.AddHowto);
},
add: function(evt) {
+ alert (SypStrings.DisabledForDemo);
+ $(document).unbind("keydown");
+ Admin.reset()
+ return;
var map = Admin.map;
var pos = map.getLonLatFromViewPortPx(evt.xy);
feature = this.update (null, pos, "", "", "");
},
del: function (feature) {
+ alert (SypStrings.DisabledForDemo);
+ return;
var form = $("#feature_delete");
form.find('input[name="fid"]').val(feature.fid);
AjaxMgr.add({
}
var xml = new OpenLayers.Format.XML().read(data);
+ if (!xml.documentElement) {
+ this.commError(SypStrings.UnconsistentError);
+ $("title").focus();
+ return;
+ }
switch (xml.documentElement.nodeName.toLowerCase()) {
case "error":
}, 0);
return;
}
+
var xml = new OpenLayers.Format.XML().read(data);
+ if (!xml.documentElement) {
+ this.commError(SypStrings.UnconsistentError);
+ $("#login_error").show();
+ window.setTimeout(function() {
+ $("#user").focus().select();
+ }, 0);
+ }
switch (xml.documentElement.nodeName.toLowerCase()) {
case "error":
return;
}
+ if (!newpass) {
+ this.commError(SypStrings.emptyPasswordError);
+ $("#pass_new").focus().select();
+ return;
+ }
+
var curpass = $("#pass_current").val();
if (newpass == curpass) {
this.commError(SypStrings.changeSamePass);
this.commError("");
+ this.disableForms();
+ alert (SypStrings.DisabledForDemo);
+ return;
+
AjaxMgr.add({
form: $("#changepass"),
oncomplete: OpenLayers.Function.bind(this.ajaxReply, this),
return;
}
+ if (!newuser_pass) {
+ this.commError(SypStrings.emptyPasswordError);
+ $("#pass_new").focus().select();
+ return;
+ }
+
this.commError("");
+ this.disableForms();
+ alert (SypStrings.DisabledForDemo);
+ return;
AjaxMgr.add({
form: $("#newuser"),
return;
}
+ var xml = new OpenLayers.Format.XML().read(data);
+ if (!xml.documentElement) {
+ // here, we need a timeout because onsend timeout sometimes has not been triggered yet
+ var self = this;
+ window.setTimeout(function() {
+ self.enableForms();
+ }, 0);
+ this.commError(SypStrings.UnconsistentError);
+ return;
+ }
+
var needFormEnabling = true;
var focusEl = null;
- var xml = new OpenLayers.Format.XML().read(data);
switch (xml.documentElement.nodeName.toLowerCase()) {
case "error":
switch (xml.documentElement.getAttribute("reason")) {
return false;
});
$("#image_delete").click(function() {
+ alert (SypStrings.DisabledForDemo);
+ return;
$("#img").removeAttr('src');
// needs to rebuild element otherwise some browsers still
// display image.