/* ----------------------------------------------------
	create the debug window
------------------------------------------------------ */
function displayDebug ( textToDisplay, shoppingStr, productId )
{
	
	var displayScrollbar = "yes" ;
	var displayTitlebar  = "no" ;
	var winWidth	   = "600" ;
	var winHeight        = "400" ;
	var winDisplayPositionText = "" ;	 	
	var debugWindow = null, browser = null ; 
	var winFeatures = "" ;
	
	// Determine browser type
	browser = new Object();
	browser.isNetscape = false ;
	browser.isMicrosoft = false ;
	if(navigator.appName.indexOf("Netscape") != -1)	{	
		browser.isNetscape = true ;
	}
	else if ( navigator.appName.indexOf("Microsoft") != -1) {	
		browser.isMicrosoft = true;
	}
	
	// Based on browser type, determine the window display position text
	if( browser.isNetscape ) { 	
		winDisplayPositionText = ",screenX=0,screenY=0" ;
	}
	else {			
		winDisplayPositionText = ",left=0,top=0" ;
	}	
	
	// Set the window features	
	windowFeatures = "width="+winWidth+",height="+winHeight+ winDisplayPositionText+",scrollbars="+displayScrollbar ;
	
	//open debug window
	debugWindow = window.open("","debugw",windowFeatures);
	debugWindow.focus() ;
	debugWindow.document.open() ;
	debugWindow.document.write('<html><head><title>debug</title><head><body bgcolor=gray>') ;
	debugWindow.document.write('<font size=+1 face=Arial,Helvetica>') ;
	debugWindow.document.write('<plaintext>' + unescape(textToDisplay).split(">").join(">\n") + '</plaintext>') ;
	debugWindow.document.write('</font></body></html>') ;
	debugWindow.document.close() ;
	
	window.open("/nikeid/temp_services/debug.jsp?xmlString="+unescape(textToDisplay),"debug2","width=600,height=400,toolbars=yes,scrollbars=yes,status=yes,location=yes");

}
