From 6c1aaba0fe8ac3d5c700f3ed897a82a45c7d861b Mon Sep 17 00:00:00 2001 From: Michael M Slusarz Date: Tue, 10 Feb 2009 00:22:01 -0700 Subject: [PATCH] Fix some typos --- imp/js/login.js | 2 +- imp/js/src/login.js | 6 +++--- imp/login.php | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/imp/js/login.js b/imp/js/login.js index 9f5822281..95843d234 100644 --- a/imp/js/login.js +++ b/imp/js/login.js @@ -1 +1 @@ -var ImpLogin={_reload:function(){window.top.document.location=this.autologin_url+$F("server_key")},submit:function(){if(this.show_list&&$F("server_key").startsWith("_")){return}if(!$F("imapuser")){alert(IMP.text.login_username);$("imapuser").focus()}else{if(!$F("pass")){alert(IMP.text.login_password);$("pass").focus()}else{$("loginButton").disable();if(this.ie_clientcaps){try{$("ie_version").setValue(objCCaps.getComponentVersion("{89820200-ECBD-11CF-8B85-00AA005B4383}","componentid"))}catch(a){}}$("imp_login").submit()}}},_selectLang:function(){if(!$F("imapuser")&&!$F("pass")){var a={new_lang:$F("new_lang")};if(this.lang_url){a.url=this.lang_url}self.location="login.php?"+Object.toQueryString(a)}},_removeHash:function(a){return(Object.isString(a)&&a.startsWith("#"))?a.substring(1):a},onDomLoad:function(){if(this.imp_auth){if(parent.frames.horde_main){if(this.nomenu){parent.location=self.location}else{document.imp_login.target="_parent"}}}document.observe("change",this._changeHandler.bindAsEventListner(this));document.observe("click",this._clickHandler.bindAsEventListner(this));if(location.hash){$("anchor_string").setValue(this._removeHash(location.hash))}if(!$F("imapuser")){$("imapuser").focus()}else{$("pass").focus()}if(this.reloadmenu&&window.parent.frames.horde_menu){window.parent.frames.horde_menu.location.reload()}},_changeHandler:function(a){switch(a.element().readAttribute("id")){case"new_lang":this._selectLang();break;case"server_key":this._reload();break}},_clickHandler:function(a){switch(a.element().readAttribute("id")){case"btn_login":this._reload();break;case"loginButton":this._submit();break}}};document.observe("dom:loaded",ImpLogin.onDomLoad.bin(ImpLogin)); \ No newline at end of file +var ImpLogin={_reload:function(){window.top.document.location=this.autologin_url+$F("server_key")},submit:function(){if(this.show_list&&$F("server_key").startsWith("_")){return}if(!$F("imapuser")){alert(IMP.text.login_username);$("imapuser").focus()}else{if(!$F("pass")){alert(IMP.text.login_password);$("pass").focus()}else{$("loginButton").disable();if(this.ie_clientcaps){try{$("ie_version").setValue(objCCaps.getComponentVersion("{89820200-ECBD-11CF-8B85-00AA005B4383}","componentid"))}catch(a){}}$("imp_login").submit()}}},_selectLang:function(){if(!$F("imapuser")&&!$F("pass")){var a={new_lang:$F("new_lang")};if(this.lang_url){a.url=this.lang_url}self.location="login.php?"+Object.toQueryString(a)}},_removeHash:function(a){return(Object.isString(a)&&a.startsWith("#"))?a.substring(1):a},onDomLoad:function(){if(this.imp_auth){if(parent.frames.horde_main){if(this.nomenu){parent.location=self.location}else{document.imp_login.target="_parent"}}}document.observe("change",this._changeHandler.bindAsEventListener(this));document.observe("click",this._clickHandler.bindAsEventListener(this));if(location.hash){$("anchor_string").setValue(this._removeHash(location.hash))}if(!$F("imapuser")){$("imapuser").focus()}else{$("pass").focus()}if(this.reloadmenu&&window.parent.frames.horde_menu){window.parent.frames.horde_menu.location.reload()}},_changeHandler:function(a){switch(a.element().readAttribute("id")){case"new_lang":this._selectLang();break;case"server_key":this._reload();break}},_clickHandler:function(a){switch(a.element().readAttribute("id")){case"btn_login":this._reload();break;case"loginButton":this._submit();break}}};document.observe("dom:loaded",ImpLogin.onDomLoad.bind(ImpLogin)); \ No newline at end of file diff --git a/imp/js/src/login.js b/imp/js/src/login.js index 62c481fe5..6fe249e58 100644 --- a/imp/js/src/login.js +++ b/imp/js/src/login.js @@ -68,8 +68,8 @@ var ImpLogin = { } } - document.observe('change', this._changeHandler.bindAsEventListner(this)); - document.observe('click', this._clickHandler.bindAsEventListner(this)); + document.observe('change', this._changeHandler.bindAsEventListener(this)); + document.observe('click', this._clickHandler.bindAsEventListener(this)); // Need to capture hash information if it exists in URL if (location.hash) { @@ -115,4 +115,4 @@ var ImpLogin = { }; -document.observe('dom:loaded', ImpLogin.onDomLoad.bin(ImpLogin)); +document.observe('dom:loaded', ImpLogin.onDomLoad.bind(ImpLogin)); diff --git a/imp/login.php b/imp/login.php index cf1976bd9..338708f36 100644 --- a/imp/login.php +++ b/imp/login.php @@ -334,7 +334,7 @@ IMP::addInlineScript(array( 'ImpLogin.imp_auth = ' . intval($imp_auth), 'ImpLogin.lang_url = ' . Horde_Serialize::serialize($lang_url, SERIALIZE_JSON, $charset), 'ImpLogin.nomenu = ' . intval(empty($conf['menu']['always'])), - 'ImpLogin.reloadmenu = ' . (boolean) ($logout_reason && $imp_auth && $conf['menu']['always']), + 'ImpLogin.reloadmenu = ' . intval($logout_reason && $imp_auth && $conf['menu']['always']), 'ImpLogin.show_list = ' . intval($show_list), )); -- 2.11.0