1 <?php require(AT_INCLUDE_PATH.'header.inc.php'); ?>
2 <div id="my_courses_container">
3 <table class="data" style="width:100%;">
5 <th><?php echo _AT('course'); ?></th>
6 <th><?php echo _AT('instructor'); ?></th>
7 <th><?php echo _AT('status'); ?></th>
8 <th><?php echo _AT('shortcuts'); ?></th>
10 <?php foreach ($this->courses as $row):
15 <tr class="<?php if ($counter %2) { echo 'odd'; } else { echo 'even'; } ?>">
17 <?php if ($row['icon'] == ''): ?>
18 <img src="images/clr.gif" class="icon" border="1" width="79" height="79" alt="<?php echo htmlentities_utf8($row['title']); ?>" />
22 $sql2="SELECT icon from ".TABLE_PREFIX."courses WHERE course_id='$row[course_id]'";
23 $result2 = mysql_query($sql2, $db);
25 while($row2=mysql_fetch_assoc($result2)){
26 $filename = $row2['icon'];
29 $path = AT_CONTENT_DIR .$row['course_id'].'/custom_icons/'.$filename;
31 if (file_exists($path)) {
32 if (defined('AT_FORCE_GET_FILE')) {
33 $dir = 'get_course_icon.php?id='.$row['course_id'];
35 $dir = 'content/' . $_SESSION['course_id'] . '/'.$row['icon'];
38 $dir = "images/courses/".$row['icon'];
41 <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
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>
84 <?php if ($row['last_cid']): ?>
85 <div class="shortcuts" style="float:right;">
86 <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>
97 <div class="current_box">
98 <div class="current_head"> <h3><?php echo _AT('things_current'); ?></h3></div>
101 //display current news
106 $p = intval($_GET['p']);
108 if($_GET['p'] == "all"){
109 $perpage = count($this->all_news);
114 $newscount = count($this->all_news);
115 $num_pages = ($perpage==0)?0:(ceil($newscount/$perpage));
116 $start = ($p-1)*$perpage;
117 $end = ($p*$perpage);
119 print_paginator($page, $num_pages, '', 1);
120 for($i=$start;$i<=$end; $i++){
122 if (isset($this->all_news)) {
123 echo '<ul class="current_list">';
124 if(isset($this->all_news[$i]['thumb'])){
125 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 />';
126 if($this->all_news[$i]['object']['course_id']){
127 echo '<small>(<a href="bounce.php?course='.$this->all_news[$i]['object']['course_id'].'">'.$this->all_news[$i]['course'].'</a>)|';
129 echo '('.AT_DATE('%F %j, %g:%i',$this->all_news[$i]['time']).')</small><hr style=""/></li>';
134 if($perpage == count($this->all_news)){ ?>
135 <a href="<?php echo $_SERVER['PHP_SELF']; ?>?p=1"><?php echo _AT('show_pages'); ?></a>
136 <?php }else if($newscount > 0){ ?>
137 <a href="<?php echo $_SERVER['PHP_SELF']; ?>?p=all"><?php echo _AT('show_all'); ?></a>
139 echo _AT('none_found');
144 <?php require(AT_INCLUDE_PATH.'footer.inc.php'); ?>