Communicationsmgr.com

Title

Welcome to Communications Manager 5.1

Description

Excerpted from the website:

----------------------------------------------------------------------------- */ function isSqlInjectionDetected(strValue) { var val = false; //EXEC if(isSQLServerAttack(strValue)) { val = true; } //INSERT else if (isInsertAttack(strValue)) { val = true; } //UPDATE else if(isUpdateAttack(strValue)) { val = true; } //DELETE else if(isDeleteAttack(strValue)) { val = true; } //DROP else if(isDropAttack(strValue)) { val = true; } //SELECT else if(isSelectAttack(strValue)) { val = true; } //UNION else if(isUnionAttack(strValue)) { val = true; } //Metachars else if(isSQLMetaCharsAttack(strValue)) { val = true; } //Typical 'or attack else if(isTypicalSQLAttack(strValue)) { val = true; } return val; }//End Function /***************************************END SQL INJECTION DETECTION******************************************/ /***************************************CROSS SITE SCRIPT ATTACK DETECTION******************************************/ function isCrossScriptAlphaNumericSymbolDetected(strValue) { var objRegExp = /((\%3C)|)/i; return objRegExp.test(strValue); } function isCrossScriptAlphaNumericDetected(strValue) { var objRegExp = /((\%3C)|)/i; return objRegExp.test(strValue); } function isCrossScriptImageDetected(strValue) { var objRegExp = /((\%3C)|)/i; return objRegExp.test(strValue); } function isCrossScriptDetected(strValue) { var val = false; if(isCrossScriptAlphaNumericSymbolDetected(strValue) == true) { val = true; } else if(isCrossScriptImageDetected(strValue)) { val = true; } return val; } /***************************************END CROSS SITE SCRIPT ATTACK DETECTION******************************************/ /***************************************FIELD SIZE*******************************************************/ /* Name :validateMaxLength Author :AW Date :8/3/2005 Description :Simple function that determines if the max length has been exceeded. Note :For onBlur Element trimming and validation of max lengths I sugguest using trimMessage() defined above. */ function validateMaxLength(strValue, maxLength) { var val; val = true; if(strValue.length > maxLength) { val = false } return val; } /**************************************END FIELD SIZE******************************************************/ /**************************************FILE OPERATIONS AND VALIDATION**************************************/ /* Name :getFileExtension Author : AW Date : 8/3/2005 Purpose : To return the file's extension to the calling browser Sample Input: test.jpg Sample Return: jpg */ function getFileExtension(strFileName) { var dot_pos = strFileName.lastIndexOf("."); var result = ""; if(dot_pos > -1) { result = strFileName.substr(dot_pos + 1).toLowerCase(); } return result; } /* Name : getFileName Author : AW Date : 8/4/2005 Description : Function that is passed a string value as a Path for example: "C:\Documents and Settings\user\Desktop\UploadMovies\Fire_fox_look.GIF" This supports both firefox and IE File Path handling Browser Diff: Inputs : strFilePath --> string representing the path to the file. Output : String that represents the filename (the extension will be included) Ex: "Fire_fox_look.GIF" NOTE : if the file is invalid and empty string will be returned Ex: "" to the calling function. */ function getFileName(strFilePath) { var nameArray; var slashPosition; var fileName = ""; //if(!strFilePath) return; slashPosition=strFilePath.lastIndexOf("\\"); if(slashPosition > 0 && strFilePath.lastIndexOf(".") > 0) { fileName = strFilePath.substring(slashPosition + 1, strFilePath.length); } else { if(strFilePath.length > 0 && strFilePath.lastIndexOf(".") > 0) { fileName = strFilePath; } } return fileName; } /* Name : validateFileNameLength Author : AW Date : 8/4/2005 Purpose : To validate that a given file name (extension included) is under a given value Inputs : strFilePath --> Path to the file location Ex: "C:\Documents and Settings\user\Desktop\UploadMovies\Fire_fox_look.GIF" NOTE: This could also be just the file name the you could pass it "Fire_fox_look.GIF" it would still validate. Outputs : Boolean : True if the file name validates as being under the max value. */ function validateFileNameLength(strFilePath, maxLength) { var fileName = ""; var val = false; fileName = getFileName(strFilePath); if(fileName.length 0) { val = true; } //Resolution return val; } /**************************************END FILE OPERATIONS AND VALIDATION**********************************/ /**************************************CROSS-BROWSER OPERATIONS********************************************/ /* Name : setFocusElement Author : AW Description : sets the page focus to a specific element by setting the timeout = 0 and focus() on the element. this is a work around for Firefox and Netscape focus(); bugs Valid Browsers: IE, Netscape, FireFox, Opera all tested fine I don't have a good copy of Safari to test on. */ function setFocusElement(formElement) { setTimeout('document.getElementById("' + formElement.id + '").focus()',0); } /* Name : setSelectElement Author : AW Description : selects the element by setting the timeout = 0 and select() on the element. this is a work around for Firefox and Netscape select(); bugs Valid Browsers: IE, Netscape, FireFox, Opera all tested fine I don't have a good copy of Safari to test on. */ function setSelectElement(formElement) { setTimeout('document.getElementById("' + formElement.id + '").select()',0); } /* Name : setSelectFocusElement Author : AW Description : sets the page selection and focus to a specific element by calling the setSelectElement & setFocusElement functions this is a work around for Firefox and Netscape focus(); bugs Valid Browsers: IE, Netscape, FireFox, Opera all tested fine I don't have a good copy of Safari to test on. */ function setSelectFocusElement(formElement) { setSelectElement(formElement); setFocusElement(formElement); } /**************************************END CROSS-BROWSER OPERATIONS****************************************/ // stop hiding -->
What is Communications Manager 5.1 Mobile?
It’s the same Communications Manager you access via the web – now available on your Windows Mobile, Palm PDA or Sony Ericcson cell phone.
read more

Languages

English

Address

2210 Vanderbilt Beach Rd, #1300
Naples FL 34109 US

Additional Information

Related Domains

External Links





Retrieved from "http://aboutus.com/index.php?title=Communicationsmgr.com&oldid=26798836"