'; //Write it to the frame TopFrame.document.clear(); TopFrame.document.open(); TopFrame.document.write(OutString); TopFrame.document.close(); } function DisplayExercise(){ //Build the output string var OutString = ''; OutString += ''; OutString += ''; OutString += '
'; OutString += TitleCode; OutString += Buttons1; OutString += BuiltExercise; OutString += Buttons2; OutString += BuiltClues; OutString += NavBar; OutString += '
'; if (is.CRAPBrowser){OutString=ResolveAllURLs(OutString);} //Write it to the frame BottomFrame.document.clear(); BottomFrame.document.open(); BottomFrame.document.write(OutString); BottomFrame.document.close(); } function BuildClue(ClueNum,x,y,Across){ var OutString = ''; if (Across == true){ if (ClueNum >= A.length){ return ''; } if (A[ClueNum] == null){ return ''; } OutString = ClueNum + '. ' + A[ClueNum]; OutString += GetAnswer; OutString = ReplaceStuff('[BoxName]', 'BA'+ClueNum, OutString); //Find out how long the answer is AnsLength = 0; i = x; j = y; while (j= D.length){ return ''; } if (D[ClueNum] == null){ return ''; } OutString = ClueNum + '. ' + D[ClueNum]; OutString += GetAnswer; OutString = ReplaceStuff('[BoxName]', 'BD'+ClueNum, OutString); //Find out how long the answer is AnsLength = 0; i = x; j = y; while (i 0){ OutString += ' '; } OutString = OutString + 'Down: ' + ClueNum + '. ' + D[ClueNum]; OutString += GetAnswer; OutString = ReplaceStuff('[BoxName]', 'BD'+ClueNum, OutString); //Find out how long the answer is AnsLength = 0; i = x; j = y; while (i-1){ FirstBit = InString.substring(0, i); LastBit = InString.substring(i + Token.length, InString.length); InString = FirstBit + Replacement + LastBit; i = InString.indexOf(Token); } return InString; } L = new Array(); L[0] = new Array('','','','','G','','','','I','S','O','L','A','','','P','A','R','M','A'); L[1] = new Array('T','I','R','R','E','N','O','','S','','','','','','','','','','A',''); L[2] = new Array('','','','','N','','','','C','','P','','','','','C','A','P','R','I'); L[3] = new Array('','N','A','P','O','L','I','','H','','A','S','S','I','S','I','','','E',''); L[4] = new Array('V','','D','','V','','','','I','','D','','','','','T','','','',''); L[5] = new Array('E','','R','','A','','','L','A','G','O','','M','O','N','T','A','G','N','A'); L[6] = new Array('N','','I','','','','','','','','V','','','','','A','','','','D'); L[7] = new Array('E','','A','S','T','I','','','','C','A','T','E','N','A','','B','A','R','I'); L[8] = new Array('Z','','T','','','','A','R','N','O','','','','','','','','','','G'); L[9] = new Array('I','','I','','','G','','','','L','A','Q','U','I','L','A','','','','E'); L[10] = new Array('A','N','C','O','N','A','','','','L','','','','','','','G','','S',''); L[11] = new Array('','','O','','','R','','','F','I','U','M','E','','','I','O','N','I','O'); L[12] = new Array('','','','','','D','','','','N','','I','','','F','','L','','E',''); L[13] = new Array('','P','','P','I','A','N','U','R','A','','L','','','I','','F','','N',''); L[14] = new Array('F','O','C','E','','','','','','','P','A','L','E','R','M','O','','A',''); L[15] = new Array('','','','R','','','','','C','','','N','','','E','','','','',''); L[16] = new Array('','','V','U','L','C','A','N','O','','T','O','R','I','N','O','','','',''); L[17] = new Array('','','','G','','','','','L','','','','','','Z','','','','',''); L[18] = new Array('','','P','I','S','A','','','L','','','','','V','E','S','U','V','I','O'); L[19] = new Array('','','','A','','','','','E','T','N','A','','','','','','','',''); C = new Array(); C[0] = new Array(0,0,0,0,1,0,0,0,2,0,0,0,0,0,0,3,0,0,4,0); C[1] = new Array(5,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0); C[2] = new Array(0,0,0,0,0,0,0,0,0,0,6,0,0,0,0,7,0,0,0,0); C[3] = new Array(0,8,9,0,0,0,0,0,0,0,10,0,0,0,0,0,0,0,0,0); C[4] = new Array(11,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0); C[5] = new Array(0,0,0,0,0,0,0,12,0,0,0,0,13,0,0,0,0,0,0,14); C[6] = new Array(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0); C[7] = new Array(0,0,15,0,0,0,0,0,0,16,0,0,0,0,0,0,17,0,0,0); C[8] = new Array(0,0,0,0,0,0,18,0,0,0,0,0,0,0,0,0,0,0,0,0); C[9] = new Array(0,0,0,0,0,19,0,0,0,20,0,0,0,0,0,0,0,0,0,0); C[10] = new Array(21,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,22,0,23,0); C[11] = new Array(0,0,0,0,0,0,0,0,24,0,0,25,0,0,0,26,0,0,0,0); C[12] = new Array(0,0,0,0,0,0,0,0,0,0,0,0,0,0,27,0,0,0,0,0); C[13] = new Array(0,28,0,29,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0); C[14] = new Array(30,0,0,0,0,0,0,0,0,0,31,0,0,0,0,0,0,0,0,0); C[15] = new Array(0,0,0,0,0,0,0,0,32,0,0,0,0,0,0,0,0,0,0,0); C[16] = new Array(0,0,33,0,0,0,0,0,0,0,34,0,0,0,0,0,0,0,0,0); C[17] = new Array(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0); C[18] = new Array(0,0,35,0,0,0,0,0,0,0,0,0,0,36,0,0,0,0,0,0); C[19] = new Array(0,0,0,0,0,0,0,0,37,0,0,0,0,0,0,0,0,0,0,0); G = new Array(); G[0] = new Array('','','','','','','','','','','','','','','','','','','',''); G[1] = new Array('','','','','','','','','','','','','','','','','','','',''); G[2] = new Array('','','','','','','','','','','','','','','','','','','',''); G[3] = new Array('','','','','','','','','','','','','','','','','','','',''); G[4] = new Array('','','','','','','','','','','','','','','','','','','',''); G[5] = new Array('','','','','','','','','','','','','','','','','','','',''); G[6] = new Array('','','','','','','','','','','','','','','','','','','',''); G[7] = new Array('','','','','','','','','','','','','','','','','','','',''); G[8] = new Array('','','','','','','','','','','','','','','','','','','',''); G[9] = new Array('','','','','','','','','','','','','','','','','','','',''); G[10] = new Array('','','','','','','','','','','','','','','','','','','',''); G[11] = new Array('','','','','','','','','','','','','','','','','','','',''); G[12] = new Array('','','','','','','','','','','','','','','','','','','',''); G[13] = new Array('','','','','','','','','','','','','','','','','','','',''); G[14] = new Array('','','','','','','','','','','','','','','','','','','',''); G[15] = new Array('','','','','','','','','','','','','','','','','','','',''); G[16] = new Array('','','','','','','','','','','','','','','','','','','',''); G[17] = new Array('','','','','','','','','','','','','','','','','','','',''); G[18] = new Array('','','','','','','','','','','','','','','','','','','',''); G[19] = new Array('','','','','','','','','','','','','','','','','','','',''); A = new Array(); A[2]='Una terra in mezzo al mare'; A[3]='La citta\' del parmigiano'; A[5]='Il mare fra Toscana e Sardegna'; A[7]='Un\'isola davanti a Napoli'; A[8]='La citta\' sotto a un vulcano'; A[10]='La citta\' di San Francesco'; A[12]='Acqua circondata dalla terra'; A[13]='Terra elevata'; A[15]='Citta\' famosa per lo spumante'; A[16]='Le Alpi sono una ... di montagne'; A[17]='Il capoluogo della Puglia'; A[18]='Fiume che attraversa Firenze'; A[20]='Citta\' vicina al Gran Sasso'; A[21]='Capoluogo delle Marche'; A[24]='Corso d\'acqua '; A[26]='Il mare della Basilicata'; A[29]='Quella padana va dal Piemonte al Veneto'; A[30]='La fine del fiume'; A[31]='Capoluogo della Sicilia'; A[33]='Una montagna che espelle lava'; A[34]='Capoluogo del Piemonte'; A[35]='La citta\' della torre pendente'; A[36]='Il vulcano che distrusse (destroyed) Pompei'; A[37]='Un vulcano attivo'; D = new Array(); D[1]='Capoluogo della Liguria'; D[2]='Un\'isola davanti a Napoli'; D[4]='Grande superficie d\'acqua fra le terre'; D[6]='Capoluogo del Veneto'; D[7]='Un centro urbano'; D[9]='Mare a est dell\'Italia'; D[11]='La citta\' su palafitte'; D[14]='Un fiume che scende dal Trentino'; D[16]='Una montagna ... piccola'; D[19]='Un famoso lago nel nord Italia'; D[22]='E\' famoso guello di Napoli'; D[23]='La citta\' di un famoso Palio'; D[25]='Capoluogo della Lombardia'; D[27]='Capoluogo della Toscana'; D[28]='Il fiume piu\' lungo d\'Italia'; D[29]='Capoluogo dell\'Umbria'; D[32]='Il Campidoglio e\' un ... di Roma'; function StartUp(){ BuildExercise(); WriteFeedback(Instructions); DisplayExercise(); } function CheckAnswers(){ var AllCorrect = true; var TotLetters = 0; var CorrectLetters = 0; //Check each letter for (var i=0; i©Half-Baked Software. Loading...'; } //--> //]]>