1 <?php require(AT_INCLUDE_PATH.'header.inc.php'); ?>
\r
2 <div class="input-form" style="width:90%;">
\r
3 <fieldset class="group_form"><legend class="group_form"><?php echo _AT('filter'); ?></legend>
\r
4 <form method="get" action="<?php echo $_SERVER['PHP_SELF']; ?>">
\r
7 <h3><?php echo _AT('results_found', $this->num_results); ?></h3>
\r
10 <?php echo _AT('access'); ?><br />
\r
11 <input type="radio" name="access" value="private" id="s1" <?php if ($_GET['access'] == 'private') { echo 'checked="checked"'; } ?> /><label for="s1"><?php echo _AT('private'); ?></label>
\r
13 <input type="radio" name="access" value="protected" id="s2" <?php if ($_GET['access'] == 'protected') { echo 'checked="checked"'; } ?> /><label for="s2"><?php echo _AT('protected'); ?></label>
\r
15 <input type="radio" name="access" value="public" id="s3" <?php if ($_GET['access'] == 'public') { echo 'checked="checked"'; } ?> /><label for="s3"><?php echo _AT('public'); ?></label>
\r
17 <input type="radio" name="access" value="" id="s" <?php if ($_GET['access'] == '') { echo 'checked="checked"'; } ?> /><label for="s"><?php echo _AT('all'); ?></label>
\r
20 <?php if ($this->has_categories): ?>
\r
22 <label for="category"><?php echo _AT('category'); ?></label><br/>
\r
23 <select name="category" id="category">
\r
24 <option value="-1">- - - <?php echo _AT('cats_all'); ?> - - -</option>
\r
25 <option value="0" <?php if ($_GET['category'] == 0) { echo 'selected="selected"'; } ?>>- - - <?php echo _AT('cats_uncategorized'); ?> - - -</option>
\r
26 <?php echo $this->categories_select; ?>
\r
32 <label for="search"><?php echo _AT('search'); ?> (<?php echo _AT('title').', '._AT('description'); ?>)</label><br />
\r
34 <input type="text" name="search" id="search" size="40" value="<?php echo htmlspecialchars($_GET['search']); ?>" />
\r
36 <?php echo _AT('search_match'); ?>:
\r
37 <input type="radio" name="include" value="all" id="match_all" <?php echo $this->checked_include_all; ?> /><label for="match_all"><?php echo _AT('search_all_words'); ?></label>
\r
38 <input type="radio" name="include" value="one" id="match_one" <?php echo $this->checked_include_one; ?> /><label for="match_one"><?php echo _AT('search_any_word'); ?></label>
\r
41 <div class="row buttons">
\r
42 <input type="submit" name="filter" value="<?php echo _AT('filter'); ?>"/>
\r
43 <input type="submit" name="reset_filter" value="<?php echo _AT('reset_filter'); ?>"/>
\r
49 <div class="container" style="width:95%; margin:auto;">
\r
50 <table class="data">
\r
53 <th><?php echo _AT('title'); ?></th>
\r
54 <th><?php echo _AT('description'); ?></th>
\r
55 <th><?php echo _AT('category'); ?></th>
\r
56 <th><?php echo _AT('instructor'); ?></th>
\r
57 <th><?php echo _AT('access'); ?></th>
\r
58 <th><?php echo _AT('shortcuts'); ?></th>
\r
60 <?php if (is_array($this->courses_rows)){ ?>
\r
61 <?php foreach ($this->courses_rows as $row){ ?>
\r
62 <?php $counter++; ?>
\r
63 <tr class="<?php if ($counter %2) { echo 'odd'; } else { echo 'even'; } ?>">
\r
66 <?php if ($row['icon']) { // if a course icon is available, display it here.
\r
67 $style_for_title = 'style="height: 1.5em;"';
\r
69 //Check if this is a custom icon, if so, use get_course_icon.php to get it
\r
70 //Otherwise, simply link it from the images/
\r
71 $path = AT_CONTENT_DIR.$row['course_id']."/custom_icons/";
\r
72 if (file_exists($path.$row['icon'])) {
\r
73 if (defined('AT_FORCE_GET_FILE') && AT_FORCE_GET_FILE) {
\r
74 $course_icon = 'get_course_icon.php/?id='.$row['course_id'];
\r
76 $course_icon = 'content/' . $row['course_id'] . '/';
\r
79 $course_icon = 'images/courses/'.$row['icon'];
\r
82 <a href="<?php echo url_rewrite('bounce.php?course='.$row['course_id'], true); ?>"><img src="<?php echo $course_icon; ?>" class="headicon" alt="<?php echo htmlentities_utf8($row['title']); ?>" style="float:left;margin-right:.5em;"/></a>
\r
86 <h3><a href="<?php echo url_rewrite('bounce.php?course='.$row['course_id'], true); ?>"><?php echo htmlentities_utf8($row['title']); ?></a></h3>
\r
89 <?php if ($row['description']): ?>
\r
90 <div style="height:6.4em;" title="<?php echo htmlentities_utf8($row['description']);?>"><?php echo substr(htmlentities_utf8($row['description'], true),0,150);
\r
91 if(strlen($row['description']) > 150){
\r
96 <div style="height:6.4em;clear:right;" title="<?php echo htmlentities_utf8($row['description']);?>"> </div>
\r
100 <?php if (is_array($this->cats) && $row['cat_id'] != 0): ?>
\r
101 <a href="<?php echo $_SERVER['PHP_SELF'].'?'.$page_string.SEP; ?>category=<?php echo $row['cat_id']; ?>"><?php echo $this->cats[$row['cat_id']]; ?></a>
\r
105 <a href="<?php echo AT_BASE_HREF; ?>contact_instructor.php?id=<?php echo $row['course_id']; ?>"><?php echo get_display_name($row['member_id']); ?></a>
\r
108 <?php echo _AT($row['access']); ?>
\r
112 // insert enrolment link if allowed
\r
113 if (isset($row['enroll_link'])) : ?>
\r
114 - <small><?php echo $row['enroll_link']; ?></small>
\r
119 <?php } // end foreach ?>
\r
120 <?php } // end if ?>
\r
124 <?php require(AT_INCLUDE_PATH.'footer.inc.php'); ?>