
		
			//<![CDATA[
				
				function getCookie( name ) {
					var start = document.cookie.indexOf( name + "=" );
					var len = start + name.length + 1;
					if ( ( !start ) && ( name != document.cookie.substring( 0, name.length ) ) ) {
						return null;
					}
					if ( start == -1 ) return null;
					var end = document.cookie.indexOf( ";", len );
					if ( end == -1 ) end = document.cookie.length;
					return unescape( document.cookie.substring( len, end ) );
				}
					
				function setCookie( name, value, expires, path, domain, secure ) {
					var today = new Date();
					today.setTime( today.getTime() );
					if ( expires ) {
						expires = expires * 1000 * 60 * 60 * 24;
					}
					var expires_date = new Date( today.getTime() + (expires) );
					document.cookie = name+"="+escape( value ) +
						( ( expires ) ? ";expires="+expires_date.toGMTString() : "" ) + //expires.toGMTString()
						( ( path ) ? ";path=" + path : "" ) +
						( ( domain ) ? ";domain=" + domain : "" ) +
						( ( secure ) ? ";secure" : "" );
				}
					
				function deleteCookie( name, path, domain ) {
					if ( getCookie( name ) ) document.cookie = name + "=" +
							( ( path ) ? ";path=" + path : "") +
							( ( domain ) ? ";domain=" + domain : "" ) +
							";expires=Thu, 01-Jan-1970 00:00:01 GMT";
				}

				// PRELOAD ROLLOVER GRAPHICS
				
				function loadBanners() {
					return false
				}

				function loadBackgrounds() {
					return false
				}
				
				function dynLoad() { // DO NOT ENABLE/LOAD THIS FUNCTION
					loadBanners();
					loadBackgrounds();
				}

				function mouseOver(theIndex) {
					return false;
				}

				function mouseOut() {
					return false;
				}

				function setFocus() {
					if(document.SEARCH) {
						document.SEARCH.Keywords.focus();
					}
				}

				function trySearch() {
					if(document.forms.SEARCH.Keywords.value != "") {
						document.forms.SEARCH.submit();
					} else {
						setFocus()
					}
				}

				function search(theForm) {
					if(theForm.Keywords.value == "") {
						return false
					}

					return true
				}

				function validateAccount(theForm) {
					// Check for zero length, empty and null values
					if(theForm.txtEmail.value.length == 0 || theForm.txtEmail.value == "" || theForm.txtEmail.value == null) {
						alert("A valid e-mail address is required to create an account.");

						theForm.txtEmail.focus();

						return false
					}

					// Check for spaces
					// var trimmedValue = theForm.txtEmail.value.replace(/^\s*|\s*$/g,"");
					
					// if(trimmedValue.length == 0) {
					// 	alert("A valid e-mail address is required to create an account.");
						
					// 	theForm.txtEmail.focus();

					// 	return false
					// }

					// Check e-mail against regex filter
					// var emailFilter = /^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/;
					// if(!emailFilter.test(theForm.txtEmail.value)) {
					// 	alert("A valid e-mail address is required to create an account.");

					// 	theForm.txtEmail.focus();

					// 	return false
					// }

					// Check the password
					if(theForm.txtPassword.value.length == 0 || theForm.txtPassword.value == "" || theForm.txtPassword.value == null) {
						alert("Please provide a valid password.");

						return false
					}

					// Check for spaces
					trimmedValue = "";
					trimmedValue = theForm.txtPassword.value.replace(/^\s*|\s*$/g,"");
					
					if(trimmedValue.length == 0) {
						alert("Please provide a valid password.");
						
						return false
					}

					// Check to see if the the password and confirmation password match
					if(theForm.txtPassword.value != theForm.txtPassword2.value) {
						alert("Your passwords do not match.");

						return false
					}

					return true
				}

				function verifyRequired() {
					if (document.LYRIS_FORM.email.value == "") {
						alert("The enter your e-mail address here field is required.");
						
						return false;
					}

					return true;
				}

				function help(theTopic, theOption) {
					var theName = "help";
					var theOptions = "height=300, width=400, status=yes, toolbar=no, menubar=no, location=no, scrollbars=yes";
					var showClose

					if(theOption == "showClose") {
						showClose = "?showclose=true";
					} else {
						showClose = "";
					}

					if(theTopic == "cvv2") {
						theFile = "/general/help/sniplets/cvv2.aspx" + showClose;
					}

					if(theTopic == "livehelpna") {
						theOptions = "height=335, width=500, status=yes, toolbar=no, menubar=no, location=no, scrollbars=no";
						theFile = "http://www.stockroom.com/general/help/sniplets/livehelpna.aspx" + showClose;
					}

					window.open(theFile, theName, theOptions);
				}
	


				function validateContact(theForm) {
					// Check for zero length, empty and null values
					if(theForm.firstName.value.length == 0 || theForm.firstName.value == "" || theForm.firstName.value == null) {
						alert("Please enter your first name.");

						theForm.firstName.focus();

						return false
					}

					if(theForm.lastName.value.length == 0 || theForm.lastName.value == "" || theForm.lastName.value == null) {
						alert("Please enter your last name.");

						theForm.lastName.focus();

						return false
					}

					if(theForm.email.value.length == 0 || theForm.email.value == "" || theForm.email.value == null) {
						alert("A valid e-mail address is required to create an account.");

						theForm.email.focus();

						return false
					}

					// Check for spaces
					var trimmedValue = theForm.email.value.replace(/^\s*|\s*$/g,"");
					
					if(trimmedValue.length == 0) {
						alert("A valid e-mail address is required to create an account.");
						
						theForm.email.focus();

						return false
					}

					// Check e-mail against regex filter
					var emailFilter = /^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/;
					if(!emailFilter.test(theForm.email.value)) {
						alert("A valid e-mail address is required to create an account.");

						theForm.email.focus();

						return false
					}

					// Check for proper subject selection
					if(theForm.subject.value.length == 0 || theForm.subject.value == "" || theForm.subject.value == null || theForm.subject.value == "0") {
						alert("Please select a valid subject.");

						theForm.subject.focus();

						return false
					}

					// Check for valid questions and comments entry
					if(theForm.comments.value.length == 0 || theForm.comments.value == "" || theForm.comments.value == null) {
						alert("Please enter your questions or comments.");

						theForm.comments.focus();

						return false
					}

				}



				function Validate(myForm) {
					if (!isLength(myForm.txtEmail.value, 1, 255)) return warnInvalid(myForm.txtEmail, "Email must be between 1 and 255 characters in length");
					if (!isEmail(myForm.txtEmail.value)) return warnInvalid(myForm.txtEmail, "Email address is invalid.");
					if (!isLength(myForm.txtPassword.value, 6, 255)) return warnInvalid(myForm.txtPassword, "Password must be at least 6 characters in length.");
					if (myForm.txtPassword.value!=myForm.txtPassword2.value) {
						return warnInvalid(myForm.txtPassword, "You did not retype your password correctly.  Please try again.");
					}
					return true;
				}
				
				 
				function calculate()
						{
							if (document.nipple_calculations.circ_mm.value == null || document.nipple_calculations.circ_mm.value == "" || document.nipple_calculations.circ_mm.value == " " )
							{
								document.nipple_calculations.circ_mm.value = 0;
								//void alert( "We need to know which job you're applying for.");
								//window.f1.job_applying_for.focus();
								//return(false);
							}
							var circum = document.nipple_calculations.circ_mm.value;
							var diameter = circum/79.7965;
							document.nipple_calculations.diam_in.value = diameter;
						}

			//]]>
