//document.onmousedown=noRightClick


function setPrintview(type,returnPage)
	{
		url = "/view_handler.asp?view=print&url=" + returnPage ;
		window.navigate(url);
	}

// disable the right click functionality 

//function noRightClick() {
//if (event.button==2) {
//alert("Copyright 2002, ColumbiaSoft Corporation - All rights reserved");
//return false;
//
//}
//}



// All client-side Javascript Functions are contained in this source file //

function cFont(that,num)
	{
		if(num == 1)
			{
				that.style.color = "red";
			}
				else
			{
				that.style.color = "black";
			}
	}

function killThis(that)
	{
		bubbleOn.style.visibility = "hidden"
		f_tab.style.visibility = "hidden";
		that.style.color = "black";
	}
	
function showBubble(that1,that,num)
	{
		that1.style.color = "red";
		f_tab.style.visibility = "";
		if(bubbleOn != "")
			{
				bubbleOn.style.visibility = "hidden";
			}
		bubbleOn = that;
		bubbleOn.style.visibility = "";
		//setTimeout('killThis(bubbleOn)',4000);
		
	}





//Flash Pop Code //

function checkdemo(dn,dw,dh)
	{
		//alert("here");
		//showflashalert();
		bubblepop(dn,'demo', dw, dh)
	}
	function getDemo(fval)
	{
		document.gDemo.demoname.value = fval;
		document.gDemo.submit();
	}


function viewTimeCard()
	{
		ID = document.tcAdminForm.timeCard.value;
		//alert(ID2)
		window.navigate("timecardViewer.asp?pc=view&userid=" + ID);
	}
	
function viewUserInfo()
	{
		ID2 = document.tcAdminForm.Info.value;
		//alert(ID2)
		window.navigate("timecarduser.asp?pc=view&userid=" + ID2);
	}
	


function checkLogin()
	{
		if(document.tcLogin.UserName.value == "")
			{
				alert("Please enter a User Name!");
				return false;
			}
		if(document.tcLogin.Password.value == "")
			{
				alert("Please enter a Password!");
				return false;
			}
		return true;
	}
	

	

	
	
	
function tcOptions(tcOption)
	{
		if (tcOption == "viewinfo")
			{
				window.navigate("timecardUser.asp")
			}
				else
			{
				window.navigate("timehandler.asp?pc=" + tcOption);
			}	
	}
	
function verifySignOut()
	{
		if (document.verifysignout.notes.value == "")
			{
				alert("Please enter notes!");
				return false;
			}
			
	}
	
function checkinfo()

	{
		return true;
	}
	
function ViewTimecard(UserID)

	{
		window.navigate("timecardviewer.asp?userID=" + UserID)
	}
	
function goBack(num)
	{
		window.history.back(num)
	}

//------> Admin Editor <-- //
function adminstylePop(bulletID)
	{
		w = (w-530) / 2;
		h = (h-580) / 2;

		cwindowOptions = "width=630, height=570, scrollbars=none, top=" + h + ", left=" + w
		//alert(windowOptions);
		theURL = "stylePop.asp?bulletID=" + bulletID;
		CssWin = window.open(theURL,"CssPopWin",cwindowOptions);
		if (CssWin.blur) CssWin.focus();
	}
function swapDEMOIMG(that,num)
	{
		if(num == 1)
			{
				that.src="/images/viewdemo1.gif";
			}
				else
			{
				that.src="/images/viewdemo.gif";
			}
	}

function swapSRCHIMG(that,num)
	{
		if(num == 1)
			{
				that.src="/images/searchsmall1.gif";
			}
				else
			{
				that.src="/images/searchsmall.gif";
			}
	}

function hlssTitle(that,that1,num)
	{

			if(num == 0)
				{
					that.style.background	= "#FDECEE";
					that1.style.background	= "#FDECEE";
					that.style.color   = "green";
					that1.style.color  = "red";
				}
					else
				{
					that.style.background	= "white";
					that1.style.background	= "white";
					that.style.color	= "black";
					that1.style.color	= "black";
				}
			


	}


function getSpan(that,wTab)
	{
		if(wTab == "DM")
			{
				that.src = "/images/tabs/DM_tab_a.gif";
				document.SCMImage.src = "/images/tabs/SCM_tab_a.gif";
				//DM Span Goes here
				//DMspan.style.z-index = "1";
				//SCMspan.style.z-index = "0";
				SCMspan.style.visibility = "hidden";
				DMspan.style.visibility = "visible";
			}
				else
			{
				that.src = "/images/tabs/SCM_tab_b.gif";
				document.DMImage.src = "/images/tabs/DM_tab_b.gif";
				//DMspan.style.z-index = "0";
				//SCMspan.style.z-index = "1";
				SCMspan.style.visibility = "visible";
				DMspan.style.visibility = "hidden";
			}
	}

function checkResolution()
	{
		w = screen.availWidth;
		h = screen.availHeight;
		if(w < 799 && h < 580)
			{
				window.navigate("/screenwarning.asp");
		  }
	}
	

function closeParent()
		{
			opener.close();
		}

function activeConsole()
	{
		w = 766 / 2;
		h = 503 / 2;
		cwindowOptions = "width=850, height=650, scrollbars=none, top=" + h + ", left=" + w
		//alert(windowOptions);
		theURL = "ConsoleBubble.asp?imageID=start"
		CssWin = window.open(theURL,"CssPopWin",cwindowOptions);
	}
			

// function for screenshot popup ---------------------------------------------//


function screenShot(imagePath,imageName,imageWidth,imageHeight,pageN,pageName)
	{
		iWidth	=	imageWidth + 100;
		iHeight	=	imageHeight + 100;
		
		if(imageName == "Locator Console")
			{
				iWidth	= 850;
				iHeight	= 680;
			}
		
		w = screen.availWidth;
		h = screen.availHeight;
		
			{
				w = (w-iWidth) / 2;
				h = (h-iHeight) / 2;
				windowOptions = "width=" + iWidth + ", height=" + iHeight  + ", scrollbars=1, resizeable=1 top=" + h + ", left=" + w
				//alert(windowOptions);
				if(pageName == "1")
					{
						theURL = "/screenshots/ssbubble.asp?imageURL=" + imagePath + "&imageName=" + imageName;
					}
						else
					{
						theURL = "/screenshots/ssbubble.asp?setID=" + imagePath
					}
				ssWin = window.open(theURL,"ssPopWin",windowOptions);
			
			}
				
		if (ssWin.blur) ssWin.focus();
		if(pageName == "1")
			{
				pURL = "screenshots.asp?pagenum=" + pageN + "&iName=" + imageName
			}
				else
			{
				pURL = "default.asp?iName=" + imageName;
			}	
		parent.navigate(pURL);
		
		
	}


function changeflash(that,numb)
	{
		if(numb == "1")
			{
				that.src = "/images/flash5_small-a.gif";
			}
				else
			{
				that.src = "/images/flash5_small.gif";
			}
	}
// ----------> Top Menu Mouseover <---------------------//

function ChangeMenu(that,num)
	{
		if(num == '0')
			{
				that.style.font.color = "red";
				//alert(num);
			}
				else
			{
				that.style.font.color = "red";
			}
	}

// --------->  Names Parent Window for Left Hand Nav iFrame <------------------//
function startup()
	{
		window.name = "parent"
	}


// ---------> redirects to demo page after closing down a Demo Pop-Up <---------------//
function mainnavigate()
	{
		opener.location = "/demos"
	}



// ------> Popups ALL funnel through this function <------------------ //
//function bubblepop(bproduct,bname, bw, bh)
//
//{
//		//showflashalert();
//		w = screen.availWidth;
//		h = screen.availHeight;
//	
//				w = (w - bw) / 2;
//				h = (h - bh) / 2;
//				windowOptions = "width=" + bw + ", height=" + bh + ", scrollbars=none, top=" + h + ", left=" + w;
//				
//		if(bname != "newkbarticle")
//			{
//				theURL = "bubble.asp?content=" + bname + "&product=" + bproduct;
//			}
//				else
//			{
//				if(bproduct != "newKBArticle")
//					{
//						theURL = "/knowledgebase/addKBArticle.asp?pc=edit&id=" + bproduct;
//					}
//						else
//					{
//						theURL = "/knowledgebase/addKBArticle.asp";
//					}
//			}
//				newWin = window.open(theURL,"bubble",windowOptions);
//				
//		if (newWin.blur) newWin.focus();
//		
//	}





// ------> Screenshot Pop Up <---------- //
function screenPop(prod)

	{
		w = screen.availWidth;
		h = screen.availHeight;
		
		if(prod == "clocator")
			{
				w = (w-725) / 2;
				h = (h-489) / 2;
				windowOptions = "width=725, height=489, scrollbars=none, top=" + h + ", left=" + w
				theURL = "screenshot.asp?product=" + prod;
				newWin = window.open(theURL,"ShowDemo",windowOptions);
			} else {
				w = (w-791) / 2;
				h = (h-625) / 2;
				windowOptions = "width=791, height=625, scrollbars=none, top=" + h + ", left=" + w
				theURL = "screenshot.asp?product=" + prod;
				newWin = window.open(theURL,"ShowDemo",windowOptions);
			}
				
		if (newWin.blur) newWin.focus();
		
	}


// ---- > Change Background on Style < ------- //
function changeBack(num,that)

	{
		//alert("test");
		if(num == 1)
			{
				that.style.background = "#FFF0C4";
				that.style.font.color = "black";
			}
				else
			{
				that.style.background = "#003982";
			}
	}
	
// ---- > Change Background on Style - BetasiteNav < ------- //
function betahomechangeBack(num,that)

	{
		//alert("test");
		if(num == 1)
			{
				that.style.background = "#cccccc";
				that.style.font.color = "#ffffff";
			}
				else
			{
				that.style.background = "#F6F6DC";
			}
	}
	
// ---- > Change Background on Style - BetasiteNav < ------- //
function overnavbar(num,that)

	{
		if(num == 1)
			{
				that.style.background = "#6486DF";
				that.style.font.color = "#ffffff";
				
			}
				else
			{
				that.style.background = "#FFFFFF";
			}
	}

// --------> mouse over Image Swapping <-------------------//	
function changeImage(num,that)
	
	{
		
		that.src = imgNum[num];
		//doMenu('1', this,spanname, x, y);
	}


// -----> PopUp for Items added to Cart <----------- //
function add2Cart(prodname)
	{
		var url = "/Main/addtoCart.asp?prodID=" + prodname
	
		var myWidth=screen.availWidth;
		var myHeight=screen.availHeight;
		wLeft = (myWidth - 500)/2
		wTop = (myHeight - 210)/2
		CSSIwindowOptions = "width=500, height=210, status=0, resize=1, top=" + wTop + ", left=" + wLeft
		popupAdd2Cart = window.open(url,"earthworm", CSSIwindowOptions);
		if (popupAdd2Cart.blur) popupAdd2Cart.focus();
		//self.close();
	
	}
	
function setFocusQTY()
	{
		document.forms(0).elements(0).setfocus
	}

function checkme(that)
	{
		if(that == "" || document.forms(0).elements(0).value == "")
			{
				alert("Please enter a quantity!");
				return false;
				that.focus;
			}
				else
			{
				add2cart.submit();
			}
	}
function fValidation()

	{
		if (checkout.firstname.value == "")
			{
				alert("Please provide your FIRST NAME!");
				return false;
			}
		if (checkout.lastname.value == "")
			{
				alert("Please provide your LAST NAME!");
				return false;
			}
		if (checkout.address1.value == "")
			{
				alert("Please provide your LINE 1 ADDRESS!");
				return false;
			}
		if (checkout.city.value == "")
			{
				alert("Please provide your CITY!");
				return false;
			}
		if (checkout.state.value == "")
			{
				alert("Please CHOOSE your STATE!");
				return false;
			}
		if (checkout.zipcode.value == "")
			{
				alert("Please provide your Zip Code!");
				return false;
			}
		if (checkout.Phone.value == "")
			{
				alert("Please provide your TELEPHONE!");
				return false;
			}
		if (checkout.email.value == "")
			{
				alert("Please provide your EMAIL ADDRESS!");
				return false;
			}
	
	return true;
	
	}

function checksitesearch()
	{
		alert("Site search not implemented as of yet!");
		return false;
	}

function zoomCart()
	
	{
		var url = "/main/zoomcart.asp"
	
		var myWidth=screen.availWidth;
		var myHeight=screen.availHeight;
		wLeft = (myWidth - 600)/2
		wTop = (myHeight - 500)/2
		CSSIwindowOptions = "width=600, height=500, top=" + wTop + ", left=" + wLeft
			
		
		popupZoomCart = window.open(url,"centipede", CSSIwindowOptions);
		if (popupZoomCart.blur) popupZoomCart.focus();
	
	}
	
function autoSubmit()

	{
		document.cartedit.submit();
	}
function clearmenu(pc,ip)
	{
		//alert(ip)
		if(pc == "")
			{
				url = "menubar.asp?home=yes";
			} else {
				url = "menubar.asp?home=yes&showproducts=yes";
			}
		parent.navigation1.location=url;
	}

function showglossary()
	{
		var popupGlossary = null;
		var url = "locatorglossary.asp"
		popupGlossary = window.open(url, 'glossary', 'width=500, height=600 resizeable=yes, scrollbars=yes, left=5, top=5');
		if (popupGlossary.blur) popupGlossary.focus();
	}
	
function changemenulocation()
	{
	//alert("test")
		parent.navigation1.location="/betasite/menubar.asp?kb=yes"
	}

	strArray = new Array(1);
	strArray[0] = "\'";
	strArray[1] = "\"";

function checkQuote(marlon) {

		var tempText = marlon.value
		for(i = 0; i < strArray.length; i++) {

			tempArray = tempText.split(strArray[i]);
			if(tempArray.length > 0) {

				tempText = tempArray.join("&quot;");

			}

		}

		marlon.value = tempText;
	}
		

function checkQuote(marlon) {

		var tempText = marlon.value
		for(i = 0; i < strArray.length; i++) {

			tempArray = tempText.split(strArray[i]);
			if(tempArray.length > 0) {

				tempText = tempArray.join("&quot;");

			}

		}

		marlon.value = tempText;
	}



function checksearch()
	{
		
		if(document.KB.searchstring.value == "")
			{
				alert("Please enter Search Criteria");
				return false;
			} 
		if(document.KB.searchtype.value == "")
			{
				alert("Please choose search type!")
				return false;
			}
				else
			{
				return true;
			}
	}
	
function checksearchmain()
	{
		if(document.KBmain.searchstring.value == "")
			{
				alert("Please enter Search Criteria");
				return false;
			} 
		
		if(document.KBmain.searchstring.value == "enter your search string here")
			{
				alert("Please enter Search Criteria");
				document.KBmain.searchstring.value = "";
				return false;
			} 
		if(document.KBmain.searchtype.value == "")
			{
				alert("Please choose search type!")
				return false;
			}
				else
			{
				return true;
			}
	}
	

	
function popUpComment(url1)
	
	{
		var myWidth=screen.availWidth;
		var myHeight=screen.availHeight;
		wLeft = (myWidth - 350)/2
		wTop = (myHeight - 150)/2
		CSSIwindowOptions = "width=550, height=325, top=" + wTop + ", left=" + wLeft
		
		var url = url1 + "&pc=newcomment"
		popupNewDiscussion = window.open(url,"cheetah",CSSIwindowOptions);
		if (popupNewDiscussion.blur) popupNewDiscussion.focus();
	
	}

function msg()
	{
		alert("You are ALREADY THERE!");
		window.status = "Columbia Software Systems Beta Site";
	}

function searchDiscussion()
	{
		var criteria = document.discussions.searchstring.value 
		if(criteria == "")
			{
				alert("Please enter search criteria");
				return false;
			}
				else
			{
				return true;
			}
			
	}
	

function searchDiscussionmain()
	{
		var criteria = document.discussionsmain.searchstring.value 
		if(criteria == "")
			{
				alert("Please enter search criteria");
				return false;
			}
				else
			{
				return true;
			}
			
	}
	

// --------------- >  AD Rotator < ----------------------- //


NewImg = new Array (
"/images/ads/clocator-1.gif",
"/images/ads/clocator-2.gif",
"/images/ads/clocator-3.gif"
);
var ImgNum = 0;
var ImgLength = NewImg.length - 1;

//Time delay between Slides in milliseconds
var delay = 4000;

var lock = false;
var run;
function chgImg(direction) {
if (document.images) {
ImgNum = ImgNum + direction;
if (ImgNum > ImgLength) {
ImgNum = 0;
}
if (ImgNum < 0) {
ImgNum = ImgLength;
}
//alert(NewImg[ImgNum]);
document.slideshow.src = NewImg[ImgNum];
   }
}
function auto() {

startup();

if (lock == true) {
lock = false;
window.clearInterval(run);
}
else if (lock == false) {
lock = true;
run = setInterval("chgImg(1)", delay);
   }
}


 // ****************  Knowledgebase stuff  ********************  //

//function deleteme1(deletetype,valu)
//	
//	{
//		var dt = deletetype;
//		var pk = valu;
//		myurl = "/beta/knowledgebase/delete_handler.asp?pc=" + dt + "&pk=" + pk
//		alert(myurl);
//		window.navigate (myurl);
//	}

function addcategory()
	
	{
		var myWidth=screen.availWidth;
		var myHeight=screen.availHeight;
		wLeft = (myWidth - 450)/2
		wTop = (myHeight - 150)/2
		CSSIwindowOptions = "width=450, height=150, top=" + wTop + ", left=" + wLeft
		
		var url = "AddNewKBCategory.asp"
		popupNewCategory = window.open(url,"cheetah",CSSIwindowOptions);
		if (popupNewCategory.blur) popupNewCategory.focus();
	
	}

function addproduct()
	
	{
		var myWidth=screen.availWidth;
		var myHeight=screen.availHeight;
		wLeft = (myWidth - 450)/2
		wTop = (myHeight - 150)/2
		CSSIwindowOptions = "width=450, height=150, top=" + wTop + ", left=" + wLeft
		
		var url = "AddNewKBProduct.asp"
		popupNewProduct = window.open(url,"cheetah",CSSIwindowOptions);
		if (popupNewProduct.blur) popupNewProduct.focus();
	
	}
	
function checkarticle()
	
	{
		if(document.NA.problemsummary.value == "")
			{
				alert("Please Enter a PROBLEM SUMMARY!")
				return false;
			}
		
		if(document.NA.problemdetails.value == "")
			{
				alert("Please enter PROBLEM DETAILS!")
				return false;
			}
			
		if(document.NA.solutionsummary.value == "")
			{
				alert("Please enter a SOLUTION SUMMARY!")
				return false;
			}
					
		if(document.NA.solutiondetails.value == "")
			{
				alert("Please enter SOLUTION DETAILS!")
				return false;
			}
			
		if(document.NA.solutionsteps.value == "")
			{
				alert("Please enter SOLUTION STEPS!")
				return false;
			
			} else {
			return true;
			}
		}



function submitemailsupport()
	{
		if(document.emailsupport.userid.value == "")
			{
				alert("Please enter your USER ID!");
				return false;
			} 
		if(document.emailsupport.email.value == "")
			{
				alert("Please enter an email address");
				return false;
			} 
		if(document.emailsupport.name.value == "")
			{
				alert("Please enter your Name");
				return false;
			} 
		if(document.emailsupport.address.value == "")
			{
				alert("Please enter your Address");
				return false;
			} 
		if(document.emailsupport.city.value == "")
			{
				alert("Please enter your City");
				return false;
			} 
		if(document.emailsupport.state.value == "")
			{
				alert("Please enter your State");
				return false;
			} 
		
		if(document.emailsupport.zip.value == "")
			{
				alert("Please enter your Zip Code");
				return false;
			} 
		if(document.emailsupport.phone.value == "")
			{
				alert("Please enter Contact Phone Number!");
				return false;
			} 
		if(document.emailsupport.comment.value == "")
			{
				alert("Please enter Problem Detail!");
				return false;
			} 		
	return true;
					
	}	
		
// ------------------> checks Comments <------------------------ //
function submitme()
	{
		if(document.comments.commenttype.value == "-SELECT REQUEST TYPE-")
			{
				alert("Please select a request type");
				document.comments.commenttype.focus();
				return false;
			} 
		if(document.comments.email.value == "")
			{
				alert("Please enter an email address");
				document.comments.email.focus();
				return false;
			} 
		if(document.comments.name.value == "")
			{
				alert("Please enter your Name");
				document.comments.name.focus();
				return false;
			} 
		if(document.comments.address.value == "")
			{
				alert("Please enter your Address");
				document.comments.address.focus();
				return false;
			} 
		if(document.comments.city.value == "")
			{
				alert("Please enter your City");
				document.comments.city.focus();
				return false;
			} 
		if(document.comments.state.value == "")
			{
				alert("Please enter your State");
				document.comments.state.focus();
				return false;
			} 
		if(document.comments.zip.value == "")
			{
				alert("Please enter your Zip Code");
				document.comments.zip.focus();
				return false;
			} 
		
		if(document.comments.phone.value == "")
			{
				alert("Please enter your Phone number");
				document.comments.phone.focus();
				return false;
			} 		
	return true;
					
	}
	
// ------------------> checks RESELLER APPLICATION <------------------------ //
function hostedreseller()
	{
		
		if(document.reseller.company.value == "")
			{
				alert("Please enter your company name.");
				return false;
			} 	
		if(document.reseller.address.value == "")
			{
				alert("Please enter your company address.");
				return false;
			} 	
		if(document.reseller.city.value == "")
			{
				alert("Please enter your company city.");
				return false;
			} 
		if(document.reseller.state.value == "")
			{
				alert("Please enter your company state.");
				return false;
			} 	
		if(document.reseller.zip.value == "")
			{
				alert("Please enter your company postal code.");
				return false;
			} 	
		if(document.reseller.phone.value == "")
			{
				alert("Please enter your company phone number.");
				return false;
			} 
		if(document.reseller.firstname.value == "")
			{
				alert("Please enter a primary contact first name.");
				return false;
			} 
		if(document.reseller.lastname.value == "")
			{
				alert("Please enter a primary contact last name.");
				return false;
			} 	
		if(document.reseller.email.value == "")
			{
				alert("Please enter a primary contact email address.");
				return false;
			} 		
	return true;
					
	}

// ------------------> VERIFY EMAIL SUPPORT <------------------------ //
function verifyemailsupport()
	{
		if(document.emailsupport.fname.value == "")
			{
				alert("Please enter your first name");
				return false;
			} 
		if(document.emailsupport.lname.value == "")
			{
				alert("Please enter your last name");
				return false;
			} 
		if(document.emailsupport.email.value == "")
			{
				alert("Please enter an email address");
				return false;
			} 
		/*if(document.emailsupport.address.value == "")
			{
				alert("Please enter your Address");
				return false;
			} 
		if(document.emailsupport.city.value == "")
			{
				alert("Please enter your City");
				return false;
			} 
		if(document.emailsupport.state.value == "-SELECT STATE-")
			{
				alert("Please enter your State");
				return false;
			} 
		if(document.emailsupport.zip.value == "")
			{
				alert("Please enter your Zip Code");
				return false;
			}*/ 
		if(document.emailsupport.producttype.value == "-SELECT PRODUCT TYPE-")
			{
				alert("Please select a product type");
				return false;
			} 
		if(document.emailsupport.comment.value == "")
			{
				alert("Please enter Comment");
				return false;
			} 
		
		if(document.emailsupport.productversion.value == "")
			{
				alert("Please enter a product version");
				return false;
			} 
		if(document.emailsupport.buildnumber.value == "")
			{
				alert("Please enter a product build number");
				return false;
			} 		
	return true;
					
	}


	
// ------------------> CHECKS ROI VALUES <------------------------ //
function verifyroi()
	{
		if(document.roi.numusers.value == "")
			{
				alert("Please enter a valid number of users.");
				return false;
			} 
		if(document.roi.avgwage.value == "")
			{
				alert("Please enter a valid average hourly wage.");
				return false;
			} 
		if(document.roi.numsearches.value == "")
			{
				alert("Please enter a valid number of searches.");
				return false;
			} 
		if(document.roi.avgsearchmins.value == "")
			{
				alert("Please enter a valid average time spent searching.");
				return false;
			} 
		if(document.roi.numversions.value == "")
			{
				alert("Please enter a valid number of times users needed to find the latest version.");
				return false;
			} 
		if(document.roi.avgversionmins.value == "")
			{
				alert("Please enter a valid number of minutes used looking for the most recent version of a document.");
				return false;
			} 
		if(document.roi.total.value == "")
			{
				alert("Please enter a valid total cost for Document Locator.");
				return false;
			} 
	return true;
					
	}
// --------------> Knowledgbase Functions <-------------------- //

function KBedituser(pc)
	{
		if(document.kbedituser.kbusername.value == "")
			{
				alert("Please select a user!");
			}
				else
			{
				parent.navigate("KBuserManagerHandler.asp?userid=" + document.kbedituser.kbusername.value + "&pc=" + pc);
			}
	}
				 
			
		
function viewKB(kbnum)
	
	{
		var url = "/support/knowledgebase/viewKBArticle.asp?kbpk=" + kbnum
	
		var myWidth=screen.availWidth;
		var myHeight=screen.availHeight;
		wLeft = (myWidth - 580)/2
		wTop = (myHeight - 700)/2
		CSSIwindowOptions = "width=580, height=700, top=" + wTop + ", left=" + wLeft + ", scrollbars=1"
			
		
		popupViewKBARTCLE = window.open(url,"centipede", CSSIwindowOptions);
		if (popupViewKBARTCLE.blur) popupViewKBARTCLE.focus();
	
	}


// ------------------> Discussions Functions <-------------------------------- //


function checkdisclogin()

	{
		if(disclogin.UserID.value == "")
			{
				alert("Please enter a User ID!");
				return false;
			}
		if(disclogin.password.value == "")
			{
				alert("Please Enter a Password!");
				return false;
			}
		return true;
	}

function newdiscussion()
	
	{
		var url = "newDiscussion.asp"
	
		var myWidth=screen.availWidth;
		var myHeight=screen.availHeight;
		wLeft = (myWidth - 350)/2
		wTop = (myHeight - 150)/2
		CSSIwindowOptions = "width=550, height=280, top=" + wTop + ", left=" + wLeft
			
		
		popupNewDiscussion = window.open(url,"cheetah", CSSIwindowOptions);
		if (popupNewDiscussion.blur) popupNewDiscussion.focus();
	
	}
	
	
function searchDiscussion()
	{
		var criteria = document.discussions.searchstring.value 
		if(criteria == "")
			{
				alert("Please enter search criteria");
				return false;
			}
				else
			{
				return true;
			}
			
	}
	

function checknewcomment()
	{
		if(document.DNC.comment.value == "")
			{
				alert("Please enter a comment!");
				return false;
			}
				else
			{
				return true;
			}
	}

function checknewdiscussion()

	{
		if(document.PN.topic.value == "")
			{
				alert("Please enter a Topic");
				return false;
			}
				else
			{
				
	
		if(document.PN.comment.value == "")
				{
					alert("Please enter a comment");
					return false;
				}
					else
				{
					return true;
				}
			}
	}



function discLogin()

	{
		if(document.discussionslogin.userID.value == "")
			{
				alert("Please enter login ID!");
				return false;
			}
				else
			{
				return true;
			}
	}
	
// ------------>  checks new user registration <------------//

function checkregistration()
	{

		if(document.register.firstname.value == "")
			{
				alert("Please enter your First Name!");
				return false;
			}
		if(document.register.lastname.value == "")
			{
				alert("Please enter your Last Name!");
				return false;
			}
		if(document.register.Phone.value == "")
			{
				alert("Please enter your Telephone!");
				return false;
			}
		//if(document.register.company.value == "")
		//	{
		//		alert("Please enter your Company Name!");
		//		return false;
		//	}
		//if(document.register.address1.value == "")
		//	{
		//		alert("Please enter your Address!");
		//		return false;
		//	}
		//if(document.register.city.value == "")
		//	{
		//		alert("Please enter your City!");
		///		return false;
		//	}
		//if(document.register.state.value == "none")
		//	{
		//		alert("Please enter your State!");
		//		return false;
		//	}
		if(document.register.email.value == "")
			{
				alert("Please enter your Email Address!");
				return false;
			}
		if(document.register.UserID.value == "")
			{
				alert("Please enter your Desired User ID!");
				return false;
			}
		if(document.register.password.value == "")
			{
				alert("Please enter desired Password!");
				return false;
			}
		return true;
	}
	
	
// ----------------------> DEMOS FUNCTIONS <------------------------------------------ //

	function dblClickDemo()
		{
			demoform11.submit();
		}

	function checkdemochoice()
		{
			if(demoform11.demoname.value == "")
				{
					alert("Please select a demo!");
					return false;
				}
					else
				{
					return true;
				}
		}


// ----------------------->  Downloads <---------------------------------------------//

function DLPopUp(dlname)
	
	{
		var myWidth=screen.availWidth;
		var myHeight=screen.availHeight;
		wLeft = (myWidth - 350)/2
		wTop = (myHeight - 450)/2
		CSSIwindowOptions = "width=350, height=450, top=" + wTop + ", left=" + wLeft
		
		var url = "bubble.asp?&pc=" + dlname;
		DLPopUpNew = window.open(url,"locomotion",CSSIwindowOptions);
		if (DLPopUpNew.blur) DLPopUpNew.focus();
	
	}

// --------------------->  Calendar Functions <-------------------------------------//

function ViewLog(ipDate)

	{
		window.navigate("IPLOG.asp?date=" + ipDate);
	}
	
	
function gotoMonth()
	{
		mNum = document.calendar.chooseMonth.value;
		window.navigate("ipLogCal.asp?cscalendar=show&monthnum=" + mNum);
	}



function changeCalBG2(that,num)

	{
		if(num == "1")
			{
				that.style.background = "#CCCC33";
				that.style.cursor     = "hand";
			}
				else
			{
				that.style.background = "lightgrey";
				that.style.cursor     = "hand";
			}
	}

function changeCalBG(that,num)

	{
		if(num == "1")
			{
				that.style.background = "#CCCC33";
				that.style.cursor     = "hand";
			}
				else
			{
				that.style.background = "white";
				that.style.cursor     = "hand";
			}
	}
function CalPopUp(bw,bh)
	{
		w = screen.availWidth;
		h = screen.availHeight;
		w = (w - bw) / 2;
				h = (h - bh) / 2;
				windowOptions = "width=" + bw + ", height=" + bh + ", top=" + h + ", left=" + w;
				
				theURL = "/calendar/calendar.asp?pc=specsheet";
				CalPopWin = window.open(theURL,"calendar",windowOptions);
				
				if (CalPopWin.blur) CalPopWin.focus();
}


// downloads - home copy


		function linkFX(that,a){
			if(a == "1"){
				that.style.textDecoration = "underline" ;
				that.style.color = "red" ;
				} else  {
				//alert("hi")
				that.style.textDecoration = "" ;
				that.style.color = "blue" ;
				}
			}
	
// ECOMM FUNCTIONS  ------

function initSCart(a){
	
		var gTg = "no" ;
		
		if(a == "PER"){
			document.add2Cart.cproductid.value = "1";
			document.add2Cart.pageview.value = "personaledition";
			gTg = "yes"
			}
			
		if(a == "SMO"){
			document.add2Cart.cproductid.value = "4";
			document.add2Cart.sproductid.value = "6";
			document.add2Cart.pageview.value = "smallofficeedition";
			gTg = "yes"
			}
			
		if(a == "PRO"){
			document.add2Cart.cproductid.value = "5";
			document.add2Cart.sproductid.value = "7";
			document.add2Cart.pageview.value = "professionaledition";
			gTg = "yes"
			}

		if(gTg == "yes"){
			document.add2Cart.submit();
			}
	}
	
