
	function Right(str, n)
        /***
                IN: str - the string we are RIGHTing
                    n - the number of characters we want to return

                RETVAL: n characters from the right side of the string
        ***/
        {
                if (n <= 0)     // Invalid bound, return blank string
                   return "";
                else if (n > String(str).length)   // Invalid bound, return
                   return str;                     // entire string
                else { // Valid bound, return appropriate substring
                   var iLen = String(str).length;
                   return String(str).substring(iLen, iLen - n);
                }
        }
        
        
        
   <!-- Hide script from old browsers
   
      window.onload = theClock

      function theClock() {
         now = new Date;
         
        
                 theTime = (now.getSeconds() > 9) ? ":" + now.getSeconds() : ":0" + now.getSeconds();
		 theTime = Right(theTime, 1);
		 theTime = "/adverts/backpacks/backpacksad" + theTime + ".html";
		
	if (window.frames.length > 1){

		if (parent.frames[1].name == "iframe1"){
		 parent.document.getElementById("iframe1").src = theTime;
		}
		

		 theTime = (now.getSeconds() > 9) ? ":" + now.getSeconds() : ":0" + now.getSeconds();
		 theTime = Right(theTime, 1);
		
		
		tpath = parent.frames[1].name;
		
		tpath = tpath.replace("ifrm", "");
		
		
		fjansport = "/adverts/" + tpath + "/" + tpath + "ad" + theTime + ".html";
			

		tpath = "ifrm" + tpath

		
		parent.document.getElementById(tpath).src = fjansport;
		

		
	}
  
      }

   // End hiding script from old browsers -->
