﻿

function check1(form){
var x = form.textbox.value;
if (x == "அவருக்கு அவனை தெரியும்"
|| x == "அவனை அவருக்கு தெரியும்" 
|| x == "அவருக்கு அவனை தெரிகிறது" 
|| x == "அவனை அவருக்கு தெரிகிறது"
){
alert("That was correct");
}
else{
alert("That is incorrect. Try again");
}
}
function check2(form){
var x = form.textbox.value;
if (x == "அவளுக்கு அலையை பார்க்க பிடிக்காது"
|| x == "அலையை பார்க்க அவளுக்கு பிடிக்காது" 

){
alert("That was correct");
}
else{
alert("That is incorrect. Try again");
}
}

function check3(form){
var x = form.textbox.value;
if (x == "எனக்கு கேள்வி உங்கள் புரியவில்லை "
|| x == "உங்கள் கேள்வி எனக்கு புரியவில்லை"

){
alert("That was correct");
}
else{
alert("That is incorrect. Try again");
}
}


function check4(form){
var x = form.textbox.value;
if (x == "எனக்கு அவருடைய பாடங்கள் புரியாது"
|| x == "அவருடைய பாடங்கள் எனக்கு புரியாது"

){
alert("That was correct");
}
else{
alert("That is incorrect. Try again");
}
}

function check5(form){
var x = form.textbox.value;
if (x == "இந்த கடையில் கோழி கிடைக்காது"
|| x == "கோழி இந்த கடையில் கிடைக்காது"

){
alert("That was correct");
}
else{
alert("That is incorrect. Try again");
}
}

function check6(form){
var x = form.textbox.value;
if (x == "எனக்கு என் வயிறு வலிக்குது எனக்கு பசிக்குது"

){
alert("That was correct");
}
else{
alert("That is incorrect. Try again");
}
}

function check7(form){
var x = form.textbox.value;
if (x == "அவர்களுக்கு கார் ஓட்ட தெரியும் அது இன்றைக்கு வரைக்கும் எனக்கு தெரியாது"
|| x == "அவர்களுக்கு கார் ஓட்ட தெரியும் இன்றைக்கு வரைக்கும் அது எனக்கு தெரியாது"

){
alert("That was correct");
}
else{
alert("That is incorrect. Try again");
}
}

function check8(form){
var x = form.textbox.value;
if (x == "ஒனக்கு தோசெ பிடிக்காது ஆனா ஒனக்கு பிரியாணி பிடிக்குமா"
|| x == "ஒனக்கு தோசெ பிடிக்காது ஆனா பிரியாணி பிடிக்குமா"

){
alert("That was correct");
}
else{
alert("That is incorrect. Try again");
}
}

function check9(form){
var x = form.textbox.value;
if (x == "எனக்கு தென் இந்தியாவெ பத்தி தெரியாது"
|| x == "தென் இந்தியாவெ பத்தி எனக்கு தெரியாது"
|| x == "தென் இந்தியாவெ பத்தி எனக்கு தெரியலெ"
|| x == "எனக்கு தென் இந்தியாவெ பத்தி தெரியலெ"
){
alert("That was correct");
}
else{
alert("That is incorrect. Try again");
}
}

function check10(form){
var x = form.textbox.value;
if (x == "அவருடைய வேலை உனக்கு புரிகிறதா"
|| x == "உனக்கு அவருடைய வேலை புரிகிறதா"


){
alert("That was correct");
}
else{
alert("That is incorrect. Try again");
}
}
function mailIt(form) {
  var data = document.mailForm
  var userInfo = "" 
 var mytext = "" 
 if(data.recipient.value == ""){ 
  alert("You must enter your teacher's address!"); 
   return false;
 }
 else{ 
 userInfo += "To: " + data.recipient.value + "\n" 
 }
 if (data.emailad.value == ""){ 
alert("You need to enter your email address also!"); 
return false;
}
 else{
userInfo += "From: " + data.emailad.value + "\n" 
}
userInfo += "Subject: " + "Student exercise" + "\n\n" 
userInfo += "Student: " + data.student.value + "\n" 
userInfo += "Page Title:  " + document.title + "\n\n" 
data = document.testForm1
if(data.textbox.value != ""){
mytext += "Sentence 1 = "  + data.textbox.value + "\n" 
}
data = document.testForm2
if(data.textbox.value != ""){
mytext += "Sentence 2 = "  + data.textbox.value + "\n" 
}
data = document.testForm3
if(data.textbox.value != ""){
mytext += "Sentence 3 = "  + data.textbox.value + "\n" 
}
data = document.testForm4
if(data.textbox.value != ""){
mytext += "Sentence 4 = "  + data.textbox.value + "\n" 
}
data = document.testForm5
if(data.textbox.value != ""){
mytext += "Sentence 5 = "  + data.textbox.value + "\n" 
}
data = document.testForm6
if(data.textbox.value != ""){
mytext += "Sentence 6 = "  + data.textbox.value + "\n" 
}
data = document.testForm7
if(data.textbox.value != ""){
mytext += "Sentence 7 = "  + data.textbox.value + "\n" 
}
data = document.testForm8
if(data.textbox.value != ""){
mytext += "Sentence 8 = "  + data.textbox.value + "\n" 
}
data = document.testForm9
if(data.textbox.value != ""){
mytext += "Sentence 9 = "  + data.textbox.value + "\n" 
}
data = document.testForm10
if(data.textbox.value != ""){
mytext += "Sentence 10 = "  + data.textbox.value + "\n" 
}
form.mailBody.value = "(bs)" + userInfo + mytext + "\n" + "(es)" 
form.action = "http://ccat.sas.upenn.edu/cgi-bin/tamil/senddata" 
return true
}

function addit(text, form){
if(form.textbox.value == ""){
form.textbox.value = text;
}
else{
form.textbox.value = form.textbox.value + " " + text;
}
}


