i have this date format 04:00
and I want to echo it to two drop down boxes, 04
for the first box and 00
for the second box by clicking the Edit button. The value 04:00
had been already display in the form page and I want it to be display on drop down boxes.
my code is this..
<?php
$_sql="SELECT day, daydesc, room, starttime, wsid, endtime, location, locationname, roomname FROM
weeklyeventscheddesc WHERE weeklyeventscheddesc.weid=".@$_GET["weid"];
}
$data = $vdb->SelectAll($_sql);
foreach ($data as $s_row)
{
$wsid= $s_row['wsid'];
$room=$s_row['room'];
$day= $s_row['day'];
$location= $s_row['location'];
/* starttime==04:00 this would be the value */
?>
<tr>
<td><?php
echo $s_row['daydesc'] ." ". $s_row['starttime']. " ". "-". " ". $s_row['endtime']. " ". " ". "  ". "  ". $s_row['locationname']. "  ". "  ". $s_row['roomname'];?>
<td align="right"><input type="submit" name="Edit" value="Edit" id="Edit2" onclick="SelectThisSched('EditSchedule','<?php echo $wsid; ?>','<?php echo $room;?>', '<?php echo $day;?>', '<?php echo $location;?>');ShowHideAdd('EditSchedule','block')"
/></td>
</td>
</tr>
<?php } ?>
and this is the javascript code
function SelectThisSched(div, wsid, room, day, location)
{
var x=0;
var s;
if (document.getElementById) {
x = document.getElementById(div);
if (x)
x.style.display = 'block';
x = document.getElementById('wsid');
if (x)
x.value = wsid;
x = document.getElementById('room');
if (x)
x.value = room;
x = document.getElementById('day');
if (x)
x.value = day;
x = document.getElementById('location');
if (x)
x.value = location;
x = document.getElementById('eActve');
if (x)
x.value = actve;
}
}
Please Help me bout my problem!!