moved code up one level to eliminate the docs subdirectory
[acontent.git] / themes / default / home / course / content.tmpl.php
1 <?php\r
2 /************************************************************************/\r
3 /* AContent                                                             */\r
4 /************************************************************************/\r
5 /* Copyright (c) 2010                                                   */\r
6 /* Inclusive Design Institute                                           */\r
7 /*                                                                      */\r
8 /* This program is free software. You can redistribute it and/or        */\r
9 /* modify it under the terms of the GNU General Public License          */\r
10 /* as published by the Free Software Foundation.                        */\r
11 /************************************************************************/\r
12 \r
13 if (!defined('TR_INCLUDE_PATH')) { exit; } ?>\r
14 \r
15 <?php if ($this->has_text_alternative || $this->has_audio_alternative || $this->has_visual_alternative || $this->has_sign_lang_alternative): ?>\r
16 <div id="alternatives_shortcuts">\r
17 <?php if ($this->has_text_alternative) :?>\r
18   <a href="<?php echo $_SERVER['PHP_SELF'].'?_cid='.$this->cid.(($_GET['alternative'] == 3) ? '' : htmlentities_utf8(SEP).'alternative=3'); ?>">\r
19     <img src="<?php echo TR_BASE_HREF; ?>images/<?php echo (($_GET['alternative'] == 3) ? 'pause.png' : 'text_alternative.png'); ?>" \r
20       alt="<?php echo (($_GET['alternative'] == 3) ? _AT('stop_apply_text_alternatives') : _AT('apply_text_alternatives')); ?>" \r
21       title="<?php echo (($_GET['alternative'] == 3) ? _AT('stop_apply_text_alternatives') : _AT('apply_text_alternatives')); ?>" \r
22       border="0" class="img1616" />\r
23   </a>\r
24 <?php endif; // END OF has text alternative?>\r
25 <?php if ($this->has_audio_alternative) :?>\r
26   <a href="<?php echo $_SERVER['PHP_SELF'].'?_cid='.$this->cid.(($_GET['alternative'] == 1) ? '' : htmlentities_utf8(SEP).'alternative=1'); ?>">\r
27     <img src="<?php echo TR_BASE_HREF; ?>images/<?php echo (($_GET['alternative'] == 1) ? 'pause.png' : 'audio_alternative.png'); ?>" \r
28       alt="<?php echo (($_GET['alternative'] == 1) ? _AT('stop_apply_audio_alternatives') : _AT('apply_audio_alternatives')); ?>" \r
29       title="<?php echo (($_GET['alternative'] == 1) ? _AT('stop_apply_audio_alternatives') : _AT('apply_audio_alternatives')); ?>" \r
30       border="0" class="img1616" />\r
31   </a>\r
32 <?php endif; // END OF has audio alternative?>\r
33 <?php if ($this->has_visual_alternative) :?>\r
34   <a href="<?php echo $_SERVER['PHP_SELF'].'?_cid='.$this->cid.(($_GET['alternative'] == 4) ? '' : htmlentities_utf8(SEP).'alternative=4'); ?>">\r
35     <img src="<?php echo TR_BASE_HREF; ?>images/<?php echo (($_GET['alternative'] == 4) ? 'pause.png' : 'visual_alternative.png'); ?>" \r
36       alt="<?php echo (($_GET['alternative'] == 4) ? _AT('stop_apply_visual_alternatives') : _AT('apply_visual_alternatives')); ?>" \r
37       title="<?php echo (($_GET['alternative'] == 4) ? _AT('stop_apply_visual_alternatives') : _AT('apply_visual_alternatives')); ?>" \r
38       border="0" class="img1616" />\r
39   </a>\r
40 <?php endif; // END OF has visual alternative?>\r
41 <?php if ($this->has_sign_lang_alternative) :?>\r
42   <a href="<?php echo $_SERVER['PHP_SELF'].'?_cid='.$this->cid.(($_GET['alternative'] == 2) ? '' : htmlentities_utf8(SEP).'alternative=2'); ?>">\r
43     <img src="<?php echo TR_BASE_HREF; ?>images/<?php echo (($_GET['alternative'] == 2) ? 'pause.png' : 'sign_lang_alternative.png'); ?>" \r
44       alt="<?php echo (($_GET['alternative'] == 2) ? _AT('stop_apply_sign_lang_alternatives') : _AT('apply_sign_lang_alternatives')); ?>" \r
45       title="<?php echo (($_GET['alternative'] == 2) ? _AT('stop_apply_sign_lang_alternatives') : _AT('apply_sign_lang_alternatives')); ?>" \r
46       border="0" class="img1616" />\r
47   </a>\r
48 <?php endif; // END OF has sign language alternative?>\r
49 </div>\r
50 <?php endif; // END OF displaying alternative shortcut icons?>\r
51 \r
52 <?php if ($this->shortcuts): ?>\r
53 <input type="hidden" name="course_id" value="<?php echo $this->course_id; ?>" />\r
54 \r
55 <fieldset id="shortcuts"><legend><?php echo _AT('shortcuts'); ?></legend>\r
56         <ul>\r
57                 <?php foreach ($this->shortcuts as $link): ?>\r
58                         <li><a href="<?php echo $link['url']; ?>"><?php echo $link['title']; ?></a></li>\r
59                 <?php endforeach; ?>\r
60         </ul>\r
61 </fieldset>\r
62 <?php endif; ?>\r
63 \r
64 <?php \r
65 if ($_SESSION["prefs"]["PREF_SHOW_CONTENTS"] && $this->content_table <> "") \r
66         echo $this->content_table;\r
67 ?>\r
68 \r
69 <div id="content-text">\r
70         <?php echo $this->body; ?>\r
71 </div>\r
72 \r
73 <?php if (!empty($this->test_ids)): ?>\r
74 <div id="content-test" class="input-form">\r
75         <ol>\r
76                 <strong><?php echo _AT('tests') . ':' ; ?></strong>\r
77                 <li class="top-tool"><?php echo $this->test_message; ?></li>\r
78                 <ul class="tools">\r
79                 <?php \r
80                         foreach ($this->test_ids as $id => $test_obj){\r
81 //                              echo '<li><a href="'.url_rewrite('tools/test_intro.php?tid='.$test_obj['test_id'], AT_PRETTY_URL_IS_HEADER).'">'.\r
82                                 echo '<li><a href="'.TR_BASE_HREF.'tests/preview.php?tid='.$test_obj['test_id'].'&_cid='.$this->cid.'">'.\r
83                                 AT_print($test_obj['title'], 'tests.title').'</a><br /></li>';\r
84                         }\r
85                 ?>\r
86                 </ul>\r
87         </li></ol>\r
88 </div>\r
89 <?php endif; ?>\r
90 \r
91 <?php if (is_array($this->forum_ids)): ?>\r
92 <div id="content-test" class="input-form">\r
93     <ol>\r
94         <strong><?php echo _AT('forums') . ':' ; ?></strong>\r
95             <ul class="tools">\r
96                 <?php\r
97                 foreach ($this->forum_ids as $id => $forum_obj) {\r
98                     echo '<li>'.AT_print($forum_obj['title'], 'forums.title').'<br /></li>';\r
99                 }\r
100                 ?>\r
101             </ul>\r
102         </li>\r
103     </ol>\r
104 </div>\r
105 <?php endif; ?>\r
106 \r
107 <div id="content-info">\r
108         <?php echo $this->content_info; ?>\r
109 \r
110 </div>