1 <?php require(AT_INCLUDE_PATH.'header.inc.php'); ?>
3 <div id="my_courses_container">
4 <table class="data" style="width:100%;">
6 <th><?php echo _AT('course'); ?></th>
7 <th><?php echo _AT('instructor'); ?></th>
8 <th><?php echo _AT('status'); ?></th>
9 <th><?php echo _AT('shortcuts'); ?></th>
11 <?php foreach ($this->courses as $row):
16 <tr class="<?php if ($counter %2) { echo 'odd'; } else { echo 'even'; } ?>">
18 <?php if ($row['icon'] == ''): ?>
19 <img src="images/clr.gif" class="icon" border="1" width="79" height="79" alt="<?php echo htmlentities_utf8($row['title']); ?>" />
23 $sql2="SELECT icon from ".TABLE_PREFIX."courses WHERE course_id='$row[course_id]'";
24 $result2 = mysql_query($sql2, $db);
26 while($row2=mysql_fetch_assoc($result2)){
27 $filename = $row2['icon'];
30 $path = AT_CONTENT_DIR .$row['course_id'].'/custom_icons/'.$filename;
32 if (file_exists($path)) {
33 if (defined('AT_FORCE_GET_FILE')) {
34 $dir = 'get_course_icon.php?id='.$row['course_id'];
36 $dir = 'content/' . $_SESSION['course_id'] . '/'.$row['icon'];
39 $dir = "images/courses/".$row['icon'];
42 <img src="<?php echo $dir; ?>" class="icon" border="0" alt="<?php echo htmlentities_utf8($row['title']); ?>" />
48 <td><?php echo '<a href="'.url_rewrite('bounce.php?course=' . $row['course_id']) . '"> '.htmlentities_utf8($row['title']).'</a>' ?>
49 <br /><small><?php echo _AT('category'); ?>: <?php echo get_category_name($row['cat_id']); ?></small>
51 <td><small><?php echo '<a href="'.AT_BASE_HREF.'inbox/send_message.php?id='.$row['member_id'].'">'. get_display_name($row['member_id']).'</a>'; ?></small></td>
55 if ($_SESSION['member_id'] == $row['member_id']) {
57 echo _AT('instructor');
58 } else if ($row['approved'] == 'a') {
61 } else if ($row['approved'] == 'n') {
63 echo _AT('pending_approval');
66 //if no role and enrolled
73 <?php if($_config['allow_unenroll'] || $row['tests']){ ?>
75 <?php if ($row['member_id'] != $_SESSION['member_id'] && $_config['allow_unenroll'] == 1): ?>
76 <li><a href="users/remove_course.php?course=<?php echo $row['course_id']; ?>"><?php echo _AT('unenroll_me'); ?></a></li>
78 <?php if ($row['tests']): ?>
79 <?php foreach ($row['tests'] as $test): ?>
80 <li><a href="bounce.php?course=<?php echo $row['course_id'].SEP.'p='.urlencode('mods/_standard/tests/test_intro.php?tid='.$test['test_id']); ?>"><span title="<?php echo _AT('tests'); ?>:<?php echo $test['title']; ?>"><?php echo $test['title']; ?></span></a> </li>
86 <?php if ($row['last_cid']): ?>
87 <div class="shortcuts" style="float:right;">
88 <a href="bounce.php?course=<?php echo $row['course_id'].SEP.'p='.urlencode('content.php?cid='.$row['last_cid']); ?>"><img src="<?php echo $_base_href; ?>themes/default/images/resume.png" border="" alt="<?php echo _AT('resume'); ?>" title="<?php echo _AT('resume'); ?>" class="img1616"/></a>
99 <div class="current_box">
100 <div class="current_head"> <h3><?php echo _AT('things_current'); ?></h3></div>
103 //display current news
108 $p = intval($_GET['p']);
110 if($_GET['p'] == "all"){
111 $perpage = count($this->all_news);
116 $newscount = count($this->all_news);
117 $num_pages = ($perpage==0)?0:(ceil($newscount/$perpage));
118 $start = ($p-1)*$perpage;
119 $end = ($p*$perpage);
121 print_paginator($page, $num_pages, '', 1);
122 for($i=$start;$i<=$end; $i++){
124 if (isset($this->all_news)) {
125 echo '<ul class="current_list">';
126 if(isset($this->all_news[$i]['thumb'])){
127 echo '<li><img src="'.$this->all_news[$i]['thumb'].'" alt="'.$this->all_news[$i]['alt'].'" title="'.$this->all_news[$i]['alt'].'" class="img1616"/> ' . $this->all_news[$i]['link'] .' <br />';
128 if($this->all_news[$i]['object']['course_id']){
129 echo '<small>(<a href="bounce.php?course='.$this->all_news[$i]['object']['course_id'].'">'.$this->all_news[$i]['course'].'</a>)|';
131 echo '('.AT_DATE('%F %j, %g:%i',$this->all_news[$i]['time']).')</small><hr style=""/></li>';
136 if($perpage == count($this->all_news)){ ?>
137 <a href="<?php echo $_SERVER['PHP_SELF']; ?>?p=1"><?php echo _AT('show_pages'); ?></a>
138 <?php }else if($newscount > 0){ ?>
139 <a href="<?php echo $_SERVER['PHP_SELF']; ?>?p=all"><?php echo _AT('show_all'); ?></a>
141 echo _AT('none_found');
146 <?php require(AT_INCLUDE_PATH.'footer.inc.php'); ?>