move code up one directory
[atutor.git] / themes / default / instructor / faq / index_instructor.tmpl.php
1
2
3 <form method="get" action="<?php echo $_SERVER['PHP_SELF']; ?>" name="form">
4 <table class="data" summary="View and edit frequently asked questions for the course" style="width: 90%;">
5 <thead>
6 <tr>
7         <th>&nbsp;</th>
8         <th style="width: 100%;"><?php echo _AT('name'); ?></th>
9 </tr>
10 </thead>
11 <tfoot>
12 <tr>
13         <td colspan="2"><input type="submit" name="edit" value="<?php echo _AT('edit'); ?>" /> 
14                                     <input type="submit" name="delete" value="<?php echo _AT('delete'); ?>" /></td>
15 </tr>
16 </tfoot>
17 <?php if (!empty($this->faq_topics)): ?>
18                 <?php foreach ($this->faq_topics as $topic_id => $row): ?>
19                                         <tr onmousedown="document.form['t<?php echo $row['topic_id']; ?>'].checked = true; rowselect(this);" id="r_<?php echo $row['topic_id']; ?>_0">
20                                         <th style="border-top:1pt solid #e0e0e0;"><input type="radio" name="item" id="t<?php echo $row['topic_id']; ?>" value="<?php echo $row['topic_id']; ?>" /></th>
21                                         <th style="border-top:1pt solid #e0e0e0;"><?php echo AT_print($row['name'], 'faqs.topic'); ?></th>
22                                         </tr>
23         
24                         <?php if (!empty($row['entry_rows'])): ?>
25                                 <?php foreach($row['entry_rows'] as $question_row): ?>
26                                 <tr onmousedown="document.form['q<?php echo $question_row['entry_id']; ?>'].checked = true; rowselect(this);" id="r_<?php echo $row['topic_id']; ?>_<?php echo $question_row['entry_id']; ?>">
27                                         <td><input type="radio" name="item" id="q<?php echo $question_row['entry_id']; ?>" value="<?php echo $question_row['entry_id']; ?>q" /></td>
28                                         <td><?php echo AT_print($question_row['question'], 'faqs.question'); ?></td>
29                                 </tr>
30                                 <?php endforeach;?>
31                         
32                         <?php else:?>
33                         <tr>
34                                         <td>&nbsp;</td>
35                                         <td><?php echo _AT('no_questions'); ?></td>
36                                 </tr>
37                         <?php endif;?>
38                 <?php endforeach; ?>
39         <tbody>
40         
41                 
42         </tbody>
43 <?php else: ?>
44         <tr>
45                 <td colspan="2"><strong><?php echo _AT('none_found'); ?></strong></td>
46         </tr>
47 <?php endif; ?>
48 </table>
49 </form>