Hi All,
I'm working on the script but nothing changed 'cause I'm very very new in Jscript. User can choose 4 seats at most per show. When the seat is clicked, it changes yellow. If user gives up the seats and clicks on it, it becomes green again. My goal is to find the reservered seats// but I couldn't make it// and insert them into database. I use PHP. Here is the code and Thanx a lot by now.

<SCRIPT LANGUAGE="JavaScript">
<!--
res = new Image
res.src = "yellow.gif"
green = new Image
green.src = "green.gif"
var num = 0

function reserveIt(picName) {
if(document[picName].src == green.src){
if (num < 4){
document[picName].src = res.src
num++
}
else {
document[picName].src = green.src
num--
return true
}
}
//-->
</SCRIPT>
<style>
td {
font-family: arial, tahoma, verdana;
font-size: 10px;
border-style: solid;
border-width: 1px;
border-color: #000033;
}
</style>
</HEAD>

<BODY>
<TABLE>
<TR>
<TD>R1seat1</TD>
<TD>R1seat2</TD>
<TD>R1seat3</TD>
<TD>R1seat4</TD>
<TD>R1seat5</TD>
</TR>
<TR>
<TD onClick="reserveIt('r1s1')"><img src="green.gif" name="r1s1" width="40"

height="30"></TD>
<TD onClick="reserveIt('r1s2')"><img src="green.gif" name="r1s2" width="40"

height="30"></TD>
<TD onClick="reserveIt('r1s3')"><img src="green.gif" name="r1s3" width="40"

height="30"></TD>
<TD onClick="reserveIt('r1s4')"><img src="green.gif" name="r1s4" width="40"

height="30"></TD>
<TD onClick="reserveIt('r1s5')"><img src="green.gif" name="r1s5" width="40"

height="30"></TD>
</TR>
<TR>
<TD>R2seat1</TD>
<TD>R2seat2</TD>
<TD>R2seat3</TD>
<TD>R2seat4</TD>
<TD>R2seat5</TD>
</TR>
<TR>
<TD onClick="reserveIt('r2s1')"><img src="green.gif" name="r2s1" width="40"

height="30"></TD>
<TD onClick="reserveIt('r2s2')"><img src="green.gif" name="r2s2" width="40"

height="30"></TD>
<TD onClick="reserveIt('r2s3')"><img src="green.gif" name="r2s3" width="40"

height="30"></TD>
<TD onClick="reserveIt('r2s4')"><img src="green.gif" name="r2s4" width="40"

height="30"></TD>
<TD onClick="reserveIt('r2s5')"><img src="green.gif" name="r2s5" width="40"

height="30"></TD>
</TR>
</TABLE>
</BODY>