[ Index ] |
|
Code source de e107 0.7.8 |
1 <?php 2 /* 3 + ----------------------------------------------------------------------------+ 4 | e107 website system 5 | 6 | ©Steve Dunstan 2001-2002 7 | http://e107.org 8 | jalist@e107.org 9 | 10 | Released under the terms and conditions of the 11 | GNU General Public License (http://gnu.org). 12 | 13 | $Source: /cvsroot/e107/e107_0.7/e107_handlers/search/search_pages.php,v $ 14 | $Revision: 1.2 $ 15 | $Date: 2005/12/14 17:37:34 $ 16 | $Author: sweetas $ 17 +----------------------------------------------------------------------------+ 18 */ 19 20 if (!defined('e107_INIT')) { exit; } 21 22 // advanced 23 $advanced_where = ""; 24 if (isset($_GET['time']) && is_numeric($_GET['time'])) { 25 $advanced_where .= " page_datestamp ".($_GET['on'] == 'new' ? '>=' : '<=')." '".(time() - $_GET['time'])."' AND"; 26 } 27 28 // basic 29 $return_fields = 'page_id, page_title, page_text, page_datestamp'; 30 $search_fields = array('page_title', 'page_text'); 31 $weights = array('1.2', '0.6'); 32 $no_results = LAN_198; 33 34 $where = "page_class IN (".USERCLASS_LIST.") AND".$advanced_where; 35 $order = array('page_datestamp' => DESC); 36 $table = "page"; 37 38 $ps = $sch -> parsesearch($table, $return_fields, $search_fields, $weights, 'search_pages', $no_results, $where, $order); 39 $text .= $ps['text']; 40 $results = $ps['results']; 41 42 function search_pages($row) { 43 global $con; 44 $res['link'] = "page.php?".$row['page_id']; 45 $res['pre_title'] = ""; 46 $res['title'] = $row['page_title']; 47 $res['summary'] = $row['page_text']; 48 $res['detail'] = LAN_SEARCH_3.$con -> convert_date($row['page_datestamp'], "long"); 49 return $res; 50 } 51 52 ?>
titre
Description
Corps
titre
Description
Corps
titre
Description
Corps
titre
Corps
Généré le : Sun Apr 1 01:23:32 2007 | par Balluche grâce à PHPXref 0.7 |