diff options
Diffstat (limited to 'view/js/mod_zchannel.js')
-rw-r--r-- | view/js/mod_zchannel.js | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/view/js/mod_zchannel.js b/view/js/mod_zchannel.js new file mode 100644 index 000000000..9f85295d7 --- /dev/null +++ b/view/js/mod_zchannel.js @@ -0,0 +1,17 @@ + $(document).ready(function() { + $("#zchannel-name").blur(function() { + var zreg_name = $("#zchannel-name").val(); + $.get("zchannel/autofill.json?f=&name=" + encodeURIComponent(zreg_name),function(data) { + $("#zchannel-nickname").val(data); + zFormError("#zchannel-name-feedback",data.error); + }); + }); + $("#zchannel-nickname").blur(function() { + var zreg_nick = $("#zchannel-nickname").val(); + $.get("zchannel/checkaddr.json?f=&nick=" + encodeURIComponent(zreg_nick),function(data) { + $("#zchannel-nickname").val(data); + zFormError("#zchannel-nickname-feedback",data.error); + }); + }); + + }); |