http://www.atutor.ca/atutor/mantis/view.php?id=4457
authorCindy Li <cli@ocad.ca>
Tue, 10 Aug 2010 15:20:37 +0000 (15:20 -0000)
committerCindy Li <cli@ocad.ca>
Tue, 10 Aug 2010 15:20:37 +0000 (15:20 -0000)
1. commented out the search section from the index page
2. increased the number of lessons displayed on the index page to 15
3. On index page, use term "Results" if the request is from search.php, otherwise, use term "Lessons"

docs/include/constants.inc.php
docs/themes/default/home/index_course.tmpl.php

index a2e3efe..a4e54c6 100644 (file)
@@ -34,7 +34,7 @@ define('VERSION',             '1.0');
 
 define('UPDATE_SERVER', 'http://update.atutor.ca/acontent');
 define('SVN_TAG_FOLDER', 'http://atutorsvn.atrc.utoronto.ca/repos/atutor/tags/');
-define('RESULTS_PER_PAGE', 10);
+define('RESULTS_PER_PAGE', 15);
 
 // language constants
 define('DEFAULT_LANGUAGE_CODE', 'en');
index 1d532d8..6970157 100644 (file)
@@ -37,7 +37,7 @@ $url_param = substr($url_param, 0, -1);
 
 if (isset($this->search_text)) $keywords = explode(' ', $this->search_text);
 ?>
-
+<!-- 
 <div class="input-form">
 <fieldset class="group_form"><legend class="group_form"><?php echo _AT('search'); ?></legend>
        <form target="_top" action="<?php echo TR_BASE_HREF; ?>home/search.php" method="get" name="frm_search">
@@ -58,6 +58,7 @@ if (isset($this->search_text)) $keywords = explode(' ', $this->search_text);
        </form>
 </fieldset>
 </div> 
+-->
 
 <div class="input-form">
 <fieldset class="group_form"><legend class="group_form"><?php echo $this->title; ?></legend>
@@ -78,7 +79,7 @@ if (isset($this->search_text)) $keywords = explode(' ', $this->search_text);
        $end_num = min($this->curr_page_num * RESULTS_PER_PAGE, $num_results);
 ?>
       <li class="course" style="font-weight:bold">
-        <div><?php echo _AT('results').' '.($start_num+1) .'-'.$end_num.' '._AT('of').' '.$num_results.' '. ($this->search_text<>'' ? _AT('for').' "<em>'.$this->search_text.'</em>"':'');?>
+        <div><?php echo ((strstr($caller_script, 'search.php') ? _AT('results'):_AT('lessons'))).' '.($start_num+1) .'-'.$end_num.' '._AT('of').' '.$num_results.' '. ($this->search_text<>'' ? _AT('for').' "<em>'.$this->search_text.'</em>"':'');?>
         <?php  
         if($_SESSION['user_id']){ ?>
           <span style="float: right"><img src="<?php echo TR_BASE_HREF; ?>themes/<?php echo $_SESSION['prefs']['PREF_THEME']; ?>/images/my_own_course.gif" alt="<?php echo _AT('my_authoring_course'); ?>" title="<?php echo _AT('my_authoring_course'); ?>" />&nbsp;&nbsp;&nbsp;<?php echo _AT('authoring_img_info'); ?></span>