default sh new scheduler time sh- get_all_tasks_format ted sql mysql_q

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
default:
$sh = new scheduler();
$time = $sh->get_all_tasks_formatted();
$sql = mysql_query("(SELECT `id`,`worker_id`,`time`,`date` FROM tasks);") or die(mysql_error());
$sql2 = mysql_query("(SELECT `active`,`email`,`first_name`,`last_name`,`home_phone`,`mobile_phone` FROM tasks_info );");
$content .= '<div class="view_tesks"><table cellpadding="1" cellspacing="1" colspan="0">
<tr><td>ID</td><td>Email</td><td>Firs and Last name</td><td>Phone</td><td>Date</td><td>Time</td><td>Workder</td><td>Active</td><td></td></tr>';
while($row = mysql_fetch_assoc($sql) AND $row2 = mysql_fetch_assoc($sql2)) {
$conv = new converter();
if($row2['active'] == 0) $active = 'No'; else $active = 'Yes';
$content .= "<tr><td>".$row['id']."</td><td>".$row2['email']."</td><td>".$row2['first_name']." ".$row2['last_name']."</td><td>Home:".$row2['home_phone']."<br>Mobile:".$row2['mobile_phone']."</td><td>".$row['date']."</td><td>".$time[$row['id']]['time']."</td><td>".$row['worker_id']."</td><td>".$active."</td><td><a href=\"admin.php?mod=tasks&do=edit&id=".$row['id']."\">Edit</a> <a href=\"admin.php?mod=tasks&do=del&id=".$row['id']."\">Delete</a></td></tr>";
}
$content .= '</table>';
break;