remove old readme
[atutor.git] / themes / simplified-desktop / instructor / content / tracker / student_usage.tmpl.php
1 <?php global $contentManager;?>
2 <form name="form" action="<?php echo $_SERVER['PHP_SELF']; ?>" method="get">
3 <div class="input-form">
4         <div class="row">
5                 <label for="id"><?php echo _AT('select_member'); ?></label><br />
6                 <select name="id" id="id">
7                         <?php
8                                 while ($row = mysql_fetch_assoc($this->result)) {
9                                         $sender = get_display_name($row['member_id']);
10                                         echo '<option value="'.$row['member_id'].'"';
11                                         if ($row['member_id'] == $_GET['id']) {
12                                                 echo ' selected="selected"';
13                                         }
14                                         echo '>'.$sender.'</option>';
15                                 }
16                         ?>
17                 </select>
18         </div>
19
20         <div class="row buttons">
21                 <input type="submit" name="submit" value="<?php echo _AT('view'); ?>" />
22         </div>
23 </div>
24 </form>
25
26 <?php if ($_GET['id']) : ?>
27 <div class="table-surround">
28         <table class="data" summary="View the usage of a specific student">
29         <thead>
30         <tr>
31                 <th scope="col"><?php echo _AT('page'); ?></th>
32                 <th scope="col"><?php echo _AT('visits'); ?></th>
33                 <th scope="col"><?php echo _AT('duration'); ?></th>
34         </tr>
35         </thead>
36         <tbody>
37         <?php if ($row = mysql_fetch_assoc($this->result_list)): ?>
38                 <?php do { ?>
39                         <tr>
40                                 <td><?php echo $contentManager->_menu_info[$row['content_id']]['title']; ?></td>
41                                 <td><?php echo $row['counter']; ?></td>
42                                 <td><?php echo $row['total']; ?></td>
43                         </tr>
44                 <?php } while ($row = mysql_fetch_assoc($this->result_list)); ?>
45         <?php else: ?>
46                 <tr>
47                         <td colspan="3"><?php echo _AT('none_found'); ?></td>
48                 </tr>
49         <?php endif; ?>
50 </tbody>
51 </table>
52 </div>
53 <?php endif; ?>