'; ResultForm += ''; ResultForm += ''; ResultForm += ''; ResultForm += ''; ResultForm += ''; ResultForm += ''; ResultForm += ''; ResultForm += ''; ResultForm += ''; ResultForm += ''; ResultForm += ''; ResultForm += '
'; var NavBar=''; NavBar+='
'; NavBar+=''; NavBar+=''; NavBar+=''; NavBar+='
'; var TitleCode = ''; TitleCode += '' + ExerciseTitle + '
'; TitleCode += '' + ExerciseSubtitle + '
'; TitleCode += '
'; var WordBox = ''; var ClozeOpener = ''; ClozeOpener += ''; var Buttons = '
'; ClozeOpener += '
'; var ClozeCloser = '
'; Buttons += '
'; Buttons += ''; Buttons += ''; Buttons += '
'; var GapCode = ''; var ClueButton = ''; ClueButton = ''; function GoBack(){ var BackSkip = history.length - PreviousPage; if (BackSkip > 0){ history.go((BackSkip+1)*-1); } else{ parent.history.back(); } } function BuildExercise(){ var OutString = ''; var ClozeStuff = ''; for (var i=0; i'; } else{ GapLen = I[i][1][0][0].length; if (GapLen < 3){GapLen = 3;} Gap = ReplaceStuff('[strGapSize]', GapLen, GapCode); Gap = ReplaceStuff('[strGapName]', 'Gap' + i + '', Gap); Gap = ReplaceStuff('[strItemNum]', i + '', Gap); Gap = ReplaceStuff('[strValue]', State[i][5], Gap); ClozeStuff += Gap; //Create and add the clue button if (I[i][2].length > 0){ Btn = ReplaceStuff('[strItemNum]', i + '', ClueButton); ClozeStuff += Btn; } } } //Add the last bit if (Text.length > I.length){ ClozeStuff += Text[Text.length-1]; } //Put the final pieces together OutString = ClozeOpener + ClozeStuff + ClozeCloser + Buttons; BuiltCloze = OutString; } function WriteFeedback(Feedback) { if (is.CRAPBrowser){Feedback=ResolveAllURLs(Feedback);} //Build the output string var OutString = ''; OutString += ''; OutString += '
'; OutString += '
'; OutString += NavBar; if (Feedback.length>0){ OutString += '' } OutString += '
'; OutString += ''; OutString += Feedback; OutString += '
'; //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 += ''; OutString += NavBar; OutString += '
'; if (WordBox.length > 0){ OutString += WordBox; } OutString += ''; OutString += BuiltCloze; 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 ShowClue(ItemNum){ //alert(ItemNum); State[ItemNum][0] = 1; WriteFeedback(I[ItemNum][2]); } function SaveCurrentAnswers(){ for (var i=0; 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; } var LowerString='abcdefghijklmnopqrstuvwxyz%9A%9C%E0%E1%E2%E3%E4%E5%E6%E7%E8%E9%EA%EB%EC%ED%EE%EF%F0%F1%F2%F3%F4%F5%F6%F8%F9%FA%FB%FC%FD%FE%FF'; var UpperString='ABCDEFGHIJKLMNOPQRSTUVWXYZ%8A%8C%C0%C1%C2%C3%C4%C5%C6%C7%C8%C9%CA%CB%CC%CD%CE%CF%D0%D1%D2%D3%D4%D5%D6%D8%D9%DA%DB%DC%DD%DE%9F'; LowerString = unescape(LowerString); UpperString = unescape(UpperString); I = new Array(); I[0] = new Array(); I[0][1] = new Array(); I[0][1][0] = new Array(); I[0][1][0][0]='was'; I[0][2]='a) has been b) have c) was d) were'; I[1] = new Array(); I[1][1] = new Array(); I[1][1][0] = new Array(); I[1][1][0][0]='by'; I[1][2]='a) to b) from c) by d) along'; I[2] = new Array(); I[2][1] = new Array(); I[2][1][0] = new Array(); I[2][1][0][0]='so'; I[2][2]='a) why b) so c) when d) instead'; I[3] = new Array(); I[3][1] = new Array(); I[3][1][0] = new Array(); I[3][1][0][0]='are linked'; I[3][2]='a) are linked b) are linking c) links d) link'; I[4] = new Array(); I[4][1] = new Array(); I[4][1][0] = new Array(); I[4][1][0][0]='to grow'; I[4][2]='a) growing b) has grown c) grows d) to grow'; I[5] = new Array(); I[5][1] = new Array(); I[5][1][0] = new Array(); I[5][1][0][0]='are coming'; I[5][2]='a) came b) are coming c) went d) got'; I[6] = new Array(); I[6][1] = new Array(); I[6][1][0] = new Array(); I[6][1][0][0]='learning software'; I[6][2]='a) software learning b) learning software c) software\'s learning d) learning\'s software'; I[7] = new Array(); I[7][1] = new Array(); I[7][1][0] = new Array(); I[7][1][0][0]='their'; I[7][2]='a) their b) his c) its d) our'; I[8] = new Array(); I[8][1] = new Array(); I[8][1][0] = new Array(); I[8][1][0][0]='those'; I[8][2]='a) they b) those c) them d) that'; I[9] = new Array(); I[9][1] = new Array(); I[9][1][0] = new Array(); I[9][1][0][0]='can'; I[9][2]='a) must b) shall c) would d) can'; Text = new Array(); Text[0]='Harold Wilson\'s \'white heat of technology\' has finally arrived nearly 40 years late - and it\'s in th'; Text[0]+='e classroom. Government figures published last month show some 86% of primary schools can access the'; Text[0]+=' web - 12,500 more than in 1998 - and 92% of secondaries are online.

Average expenditure'; Text[0]+=' from central government on ICT for teaching and learning '; Text[1]=' £41,800 per school in 1999. So how is the future shaping up? Firstly, in schools that have moved ah'; Text[1]+='ead most in ICT (Information Communications Technology), developments have been driven '; Text[2]=' empowered and connected teachers confident enough to shape ICT to meet their classroom. Secondly, t'; Text[2]+='he progress of ICT in whole class teaching points to the end of \'computer room mentality\', and wirel'; Text[2]+='ess communication and portable computers have played a major part here. Last month the Isle of Man b'; Text[2]+='ought 500 Airport wireless networking cards for the teachers\' Apple laptop computers '; Text[3]=' they can move about the class with their machines and still stay connected to the internet and netw'; Text[3]+='ork printers. And now in Cornwallis School, Maidstone, over 100 Acer laptop computers '; Text[4]=' to a school-wide wireless network.

Thirdly, new collaborative learning software and perm'; Text[4]+='anent high speed access to resources over the internet is allowing inter-school conferencing and com'; Text[4]+='munication '; Text[5]=', using voice and image tools alongside text. In five years\' time \'computer rooms\' will be a thing o'; Text[5]+='f the past, just like separate rooms for the TV or the blackboard. Computers '; Text[6]=' to the classroom, not vice-versa.

New types of collaborative '; Text[7]=' like RM\'s Discourse are starting to emerge. Here students and teachers can collaborate and question'; Text[7]+=' as they build '; Text[8]=' own bodies of knowledge over school computer networks. It gives a digital alternative to the \'hands'; Text[8]+=' up\' method of classroom interaction with obvious benefits for '; Text[9]=' too shy or unsure to go public. Whole class teaching with ICT has taken hold in many schools thanks'; Text[9]+=' to a rise in quality and a drop in price of the data projector - a device that takes the computer d'; Text[9]+='isplay and projects it onto any wall or screen so that the whole class may see and share. To help te'; Text[9]+='achers further, many companies provide interactive whiteboards - in effect giant touchscreens throug'; Text[9]+='h which teachers '; Text[10]=' operate the computer.'; State = new Array(); CharList = new Array(); EscapeList = new Array(); function StartUp(){ //Try to get user name UserName = prompt('Please enter your name and ID number',''); UserName += ''; if ((UserName.substring(0,4) == 'null')||(UserName.length < 1)){ UserName = prompt('Please enter your name and ID number',''); UserName += ''; if ((UserName.substring(0,4) == 'null')||(UserName.length < 1)){ window.location = PreviousPage; } } var i = 0; for (i=0; i 0){ OutString += FoundCode; } else{ OutString += NextChar; } } return OutString; } var MacChars = '%80%81%82%83%84%85%86%87%88%89%8A%8B%8C%8D%8E%8F%90%91%92%93%94%95%96%97%98%99%9A'; MacChars += '%9B%9C%9D%9E%9F%A0%A1%A4%A5%A6%A7%A8%AA%AB%AC%AE%AF%B4%B6%BB%BC%BE%BF%C0%C1%C2%C4%C7%C8'; MacChars += '%C9%CA%CB%CC%CD%CE%CF%D0%D1%D2%D3%D4%D5%D6%D8%D9%DA%DB%DC%DD%E0%E1%E2%E3%E4%E5%E6%E7%E8%E9'; MacChars += '%EA%EB%EC%ED%EE%EF%F1%F2%F3%F4%F5%F6%F7%F8%FB%FD'; var WinChars = '%C4%C5%C7%C9%D1%D6%DC%E1%E0%E2%E4%E3%E5%E7%E9%E8%EA%EB%ED%EC%EE%EF%F1%F3%F2%F4'; WinChars += '%F6%F5%FA%F9%FB%FC%86%BA%A7%95%B6%DF%AE%99%92%A8%C6%D8%A5%F0%AA%BA%E6%F8%BF%A1%AC%83%AB%BB'; WinChars += '%85%82%C0%C3%D5%8C%9C%96%97%93%94%91%92%F7%FFY/%A4%8B%9B%87%B7%82%84%89%C2%CA%C1%CB'; WinChars += '%C8%CD%CE%CF%CC%D3%D4%D2%DA%DB%D9%B9%88%98%AF%B0%94'; WinChars = unescape(WinChars); MacChars = unescape(MacChars) function MacStringToWin(InString){ var OutString = ''; for (i=0; i '~') && (MacChars.indexOf(InString.charAt(i)) > -1) ){ OutString += WinChars.charAt(MacChars.indexOf(InString.charAt(i))); } else { OutString += InString.charAt(i); } } return OutString; } function WinStringToMac(InString){ var OutString = ''; for (i=0; i '~') && (WinChars.indexOf(InString.charAt(i)) > -1) ){ OutString += MacChars.charAt(WinChars.indexOf(InString.charAt(i))); } else { OutString += InString.charAt(i); } } return OutString; } function TrimString(InString){ var x = 0 if (InString.length != 0) { while ((escape(InString.charAt(InString.length - 1)) == '%20') || (escape(InString.charAt(InString.length - 1)) == '%0A') || (escape(InString.charAt(InString.length - 1)) == '%0D')){ InString = InString.substring(0, InString.length - 1) } while ((escape(InString.charAt(0)) == '%20') || (escape(InString.charAt(0)) == '%0A') || (escape(InString.charAt(0)) == '%0D')){ InString = InString.substring(1, InString.length) } while (InString.indexOf(' ') != -1) { x = InString.indexOf(' ') InString = InString.substring(0, x) + InString.substring(x+1, InString.length) } return InString; } else { return ''; } } function ConvertCase(InString, Direction){ var FromString = ''; var ToString = ''; if (Direction == 0){ FromString = UpperString; ToString = LowerString; } else{ FromString = LowerString; ToString = UpperString; } var i = 0; j = 0; var OutString = ''; for (i=0; i -1){ j = FromString.indexOf(InString.charAt(i)); OutString += ToString.charAt(j); } else{ OutString += InString.charAt(i); } } return OutString; } function CheckAnswers(){ SaveCurrentAnswers(); var AllCorrect = 1; //Check each answer for (var i = 0; i< I.length; i++){ if (State[i][4] != 1){ //If it's right, calculate its score if (CheckAnswer(i, true) > -1){ var TotalChars = GetGapValue(i).length; State[i][3] = (TotalChars-State[i][1])/TotalChars; if (State[i][0] > 0){State[i][3] = State[i][3]/2;} if (State[i][3]<0){State[i][3] = 0;} State[i][4] = 1; } else{ //Otherwise, add zero to the array and increment the hints for this item, as a penalty State[i][1]++; State[i][3] = 0; //then set the flag AllCorrect = 0; } } } //Calculate the total score var TotalScore = 0; for (i=0; i'; } Output += YourScoreIs + ' ' + TotalScore + '%.
'; if (AllCorrect == 0){ Output += '
' + Incorrect; } BuildExercise(); WriteFeedback(Output); if (AllCorrect==1){ setTimeout('SendResults(' + TotalScore + ')', 50); return; } DisplayExercise(); RestoreCurrentAnswers(); } function TrackFocus(BoxNumber){ CurrentWord = BoxNumber; } function CheckBeginning(Guess, Answer){ var OutString = ''; var i = 0; var UpperGuess = ''; var UpperAnswer = ''; if (CaseSensitive == false) { UpperGuess = ConvertCase(Guess, 1); UpperAnswer = ConvertCase(Answer, 1); } else { UpperGuess = Guess; UpperAnswer = Answer; } while (UpperGuess.charAt(i) == UpperAnswer.charAt(i)) { OutString += Guess.charAt(i); i++; } OutString += Answer.charAt(i); return OutString; } function FindLongest(InArray){ if (InArray.length < 1){return -1;} var Longest = 0; for (var i=1; i InArray[Longest].length){ Longest = i; } } return Longest; } function GetGapValue(GNum){ var RetVal = ''; if ((GNum<0)||(GNum>=I.length)){return RetVal;} if (eval('BottomFrame.document.Cloze.Gap' + GNum) != null){ RetVal = eval('BottomFrame.document.Cloze.Gap' + GNum).value; if (FlipChars==true){RetVal = MacStringToWin(RetVal);} RetVal = TrimString(RetVal); } else{ RetVal = State[GNum][5]; } return RetVal; } function SetGapValue(GNum, Val){ if ((GNum<0)||(GNum>=I.length)){return;} if (FlipChars==true){Val = WinStringToMac(Val);} if (eval('BottomFrame.document.Cloze.Gap' + GNum) != null){ eval('BottomFrame.document.Cloze.Gap' + GNum).value = Val; } } function FindCurrent() { var x = 0; FoundCurrent = -1; //Test the current word: //If it's state is not set to already correct, check the word. if (State[CurrentWord][4] != 1){ if (CheckAnswer(CurrentWord, false) < 0){ return CurrentWord; } } x=CurrentWord + 1; while (x -1){return ''} RightBits = new Array(); for (var i=0; i 0){ SetGapValue(CurrGap, HintString); State[CurrGap][1] = State[CurrGap][1] + 1; } WriteFeedback(GiveHint); } function SendResults(Score){ var today = new Date; var NewName = '' + today.getTime(); var NewWin = window.open('', NewName, 'toolbar=no,location=no,directories=no,status=no, menubar=no,scrollbars=yes,resizable=no,,width=400,height=300'); NewWin.document.clear(); NewWin.document.open(); NewWin.document.write(ResultForm); NewWin.document.close(); NewWin.document.Results.Score.value = Score + '%'; NewWin.document.Results.realname.value = UserName; NewWin.document.Results.End_Time.value = (new Date()).toLocaleString(); NewWin.document.Results.Start_Time.value = StartTime; NewWin.document.Results.submit(); } function Blank(){ return '
©Half-Baked Software. Loading...
'; } //--> //]]>
-->