Wednesday, 14 August 2013

How to display alert when system time is equal to time fetched from database?

How to display alert when system time is equal to time fetched from database?

What I want to know is there any way when ($res[6] == system time),it
would display an alert saying "you've got a callback",that will display
until OK button is pressed. Any help is greatly appreciated...Thanks in
advance
<table border="1" cellspacing="1" cellpadding="1" width="100%" >
<tr>
<td align="center" valign="top" width="20%">Customer Name </td>
<td align="center" valign="top" width="20%">Callback Date </td>
<td align="center" valign="top" width="20%">Callback Time </td>
<td align="center" valign="top" width="20%">Contact Number </td>
<td align="center" valign="top" width="10%">Edit </td>
<td align="center" valign="top" width="10%">Delete </td>
</tr>
<?php
include("config.php");
$sql = "Select * from callback where userid='$agent_id'";
$result = mysql_query($sql);
while($res = mysql_fetch_array($result))
{
if($res[7] == '0')
{
?>
<tr>
<td align="center" valign="top" width="20%"><?php echo $res[4] ?></td>
<td align="center" valign="top" width="20%"><?php echo $res[5]; ?></td>
<td align="center" valign="top" width="20%"><?php echo $res[6]; ?></td>
<td align="center" valign="top" width="20%"><?php echo $res[9]; ?></td>
<td align="center" valign="top" width="10%"><a
href="editcallback.php?id=<?= $res[0];?>">edit</a></td>
<td align="center" valign="top" width="10%"><a
href="deletecallback.php?id=<?=$res[0];?>"
onclick="ValidateOnDelete()">delete</a></td>
</tr>
<?php }
else
{
?>
<tr bgcolor="#F2CBC9">
<td align="center" valign="top" width="20%"><?php echo $res[4] ?></td>
<td align="center" valign="top" width="20%"><?php echo $res[5]; ?></td>
<td align="center" valign="top" width="20%"><?php echo $res[6]; ?></td>
<td align="center" valign="top" width="20%"><?php echo $res[9]; ?></td>
<td align="center" valign="top" width="10%"><a
href="editcallback.php?id=<?= $res[0];?>">edit</a></td>
<td align="center" valign="top" width="10%"><a
href="deletecallback.php?id=<?=$res[0];?>"
onclick="ValidateOnDelete()">delete</a></td>
</tr>
<?php
}
}
?>
</table>

No comments:

Post a Comment