linea21-core
[ class tree: linea21-core ] [ index: linea21-core ] [ all elements ]

Source for file list.php

Documentation is available at list.php

  1. <?php
  2. /**
  3.  * @package linea21.core
  4.  * @subpackage search
  5.  * @author linea21 <info@linea21.com>
  6.  * @version $id SVN
  7.  * @access public
  8.  * @license http://opensource.org/licenses/gpl-3.0.html
  9.  */
  10. ?>
  11. <div id="chemin">
  12. <ul>
  13.     <li><a href="index.php" class="chemin_home"><?php echo _t('way','home');?></a>
  14.     </li>
  15.     <li><a href="<?php echo $rub_link?>" id="chemin_<?php echo $rub?>"
  16.         class="chemin_rub"><?php echo _t('menu','search');?></a></li>
  17.     <li><span><?php echo formatNavTitle(_t('menu_alt',$rub)) ?></span></li>
  18. </ul>
  19. </div>
  20. <!--end barre haute -->
  21.  
  22. <?php
  23. include_once(THEME_ADMIN_PATH."quickicons.php");
  24. ?>
  25. <div class="contentcontainer"><?php include_once($dir "/menurub.php")?>
  26. <div id="content">
  27. <?php
  28. if (!isset($_POST['valid'])) {
  29.   echo '<h2>' _t('menu','search''</h2>' END_LINE;
  30. ?>
  31.   <form action="<?php echo $_SERVER['PHP_SELF'];?>" method="post">
  32.     <div id="searchcontent">
  33.         <label for="search"><?php echo _t('search','keywords');?></label>
  34.         <input type="text" maxlength="150" class="textfield" name="search" id="search" style="margin-right: 30px" /> <br class="brendstep" />
  35.         <div style="margin: 3em 200px">
  36.             <input type="radio" name="searchtype" id="searchtype_1" value="one" checked="checked" />
  37.             <label for="searchtype_1" class="autowidth"><?php echo _t('search','one_of_them');?></label>
  38.             <input type="radio" name="searchtype" id="searchtype_2" value="all" />
  39.             <label for="searchtype_2" class="autowidth"><?php echo _t('search','all_of_them');?></label>
  40.             <input type="radio" name="searchtype" id="searchtype_3" value="exp" />
  41.             <label for="searchtype_3" class="autowidth"><?php echo _t('search','expression');?></label>
  42.         </div>
  43.         <input type="hidden" name="rub" id="rubsearch" value="<?php echo $rub;?>" />
  44.         <br class="brendstep" />
  45.         <input type="submit" value="<?php echo _t('search','text_button');?>" size="15" name="valid" class="button" id="validsearch" />
  46.     </div>
  47.    </form>
  48. <?php
  49. else {
  50.   $type 'ADMIN';
  51.   include_once($dir "/display.php");
  52.   if (!isset($_REQUEST['search']|| strlen($_REQUEST['search']<= 3)
  53.   {
  54.     echo '<div class="info">'.END_LINE;
  55.     echo _t('search','min_length');
  56.     echo  '</div>'.END_LINE;
  57.   else {
  58.     if (isset($_REQUEST['searchincome'])) $str trim($_REQUEST['searchincome']);
  59.     else $str $_REQUEST['search'];
  60.     if (!isset($_REQUEST['searchtype'])) $searchtype 'one';
  61.     else $searchtype $_REQUEST['searchtype'];
  62.     if($searchtype=='one'$display_method=_t('search','one_of_them');
  63.     if($searchtype=='all'$display_method=_t('search','all_of_them');
  64.     if($searchtype=='exp'$display_method=_t('search','expression');
  65.     echo '<h2>' _t('search','result''</h2>' END_LINE;
  66.  
  67.     echo '<div id="KeyWords">'.END_LINE;
  68.     echo _t('search','keywords');
  69.     echo formatText($str'2HTML').'<br />'.END_LINE;
  70.     echo _t('search','method');
  71.     echo $display_method.'<br />'.END_LINE;
  72.     echo '</div>'.END_LINE;
  73.     $start_time getmicrotime();
  74.     if ($rub == 'home'$rub 'all';
  75.     switch ($rub{
  76.       case 'project':
  77.         IsSuperAdmin(DisplaySearchProject($str$type$searchtypeReloadIndex('admin');
  78.         break;
  79.       case 'news':
  80.         hasRight('news'DisplaySearchNews($str$type$searchtypeReloadIndex('admin');
  81.         break;
  82.       case 'newsletter':
  83.         IsSuperAdmin(DisplaySearchNewsletter($str$type$searchtypeReloadIndex('admin');
  84.         break;
  85.       case 'publication':
  86.         hasRight('publication'DisplaySearchPublication($str$type$searchtypeReloadIndex('admin');
  87.         hasRight('publication'DisplaySearchPubliContents($str$type$searchtypeReloadIndex('admin');
  88.         break;
  89.       case 'workshop':
  90.         hasRight('workshop'DisplaySearchWorkshop($str$type$searchtypeReloadIndex('admin');
  91.         hasRight('workshop'DisplaySearchWorkshopRep($str$type$searchtypeReloadIndex('admin');
  92.         hasRight('workshop'DisplaySearchWorkshopRepContents($str$type$searchtypeReloadIndex('admin');
  93.         hasRight('workshop'DisplaySearchWorkshopCalendar($str$type$searchtypeReloadIndex('admin');
  94.         hasRight('workshop'DisplaySearchWorkshopCom($str$type$searchtypeReloadIndex('admin');
  95.         break;
  96.       case 'workshoprep':
  97.         hasRight('workshop'DisplaySearchWorkshopRep($str$type$searchtypeReloadIndex('admin');
  98.         hasRight('workshop'DisplaySearchWorkshopRepContents($str$type$searchtypeReloadIndex('admin');
  99.         break;
  100.       case 'dashboard':
  101.         hasRight('dashboard'DisplaySearchSdi($str$type$searchtypeReloadIndex('admin');
  102.         break;
  103.       case 'sdi':
  104.         hasRight('dashboard'DisplaySearchSdi($str$type$searchtypeReloadIndex('admin');
  105.         break;
  106.       case 'comment':
  107.         IsSuperAdmin(DisplaySearchComment($str$type$searchtypeReloadIndex('admin');
  108.         break;
  109.       case 'yellowpages':
  110.         IsSuperAdmin(DisplaySearchYellowpages($str$type$searchtypeReloadIndex('admin');
  111.         break;
  112.       case 'user':
  113.         IsSuperAdmin(DisplaySearchUser($str$type$searchtypeReloadIndex('admin');
  114.         break;
  115.       case 'theme':
  116.         IsSuperAdmin(DisplaySearchTheme($str$type$searchtypeReloadIndex('admin');
  117.         break;
  118.       case 'scale':
  119.         IsSuperAdmin(DisplaySearchScale($str$type$searchtypeReloadIndex('admin');
  120.         break;
  121.       case 'level':
  122.         IsSuperAdmin(DisplaySearchLevel($str$type$searchtypeReloadIndex('admin');
  123.         break;
  124.       case 'all':
  125.         if (IsSuperAdmin()) DisplaySearchProject($str$type$searchtype);
  126.         echo '<hr />';
  127.         if (hasRight('news')) DisplaySearchNews($str$type$searchtype);
  128.         echo '<hr />';
  129.         if (IsSuperAdmin()) DisplaySearchNewsletter($str$type$searchtype);
  130.         echo '<hr />';
  131.         if (hasRight('publication')) DisplaySearchPublication($str$type$searchtype);
  132.         if (hasRight('publication')) DisplaySearchPubliContents($str$type$searchtype);
  133.         echo '<hr />';
  134.         if (hasRight('workshop')) DisplaySearchWorkshop($str$type$searchtype);
  135.         if (hasRight('workshop')) DisplaySearchWorkshopRep($str$type$searchtype);
  136.         if (hasRight('workshop')) DisplaySearchWorkshopRepContents($str$type$searchtype);
  137.         if (hasRight('workshop')) DisplaySearchWorkshopCalendar($str$type$searchtype);
  138.         if (hasRight('workshop')) DisplaySearchWorkshopCom($str$type$searchtype);
  139.         echo '<hr />';
  140.         if (hasRight('dashboard')) DisplaySearchSdi($str$type$searchtype);
  141.         echo '<hr />';
  142.         if (IsSuperAdmin()) DisplaySearchComment($str$type$searchtype);
  143.         echo '<hr />';
  144.         if (IsSuperAdmin()) DisplaySearchYellowpages($str$type$searchtype);
  145.         echo '<hr />';
  146.         if (IsSuperAdmin()) DisplaySearchUser($str$type$searchtype);
  147.         echo '<hr />';
  148.         if (IsSuperAdmin()) DisplaySearchTheme($str$type$searchtype);
  149.         echo '<hr />';
  150.         if (IsSuperAdmin()) DisplaySearchScale($str$type$searchtype);
  151.         echo '<hr />';
  152.         if (IsSuperAdmin()) DisplaySearchLevel($str$type$searchtype);
  153.         echo '<hr />';
  154.         break;
  155.       default:
  156.     }
  157.     $end_time getmicrotime();
  158.     DisplayQueryTime($start_time$end_time);
  159.     logfile(LOG_KEYWORDS,array($str$type$searchtype$rubi2c_realip()));
  160.   }
  161. }
  162. ?>
  163. </div>
  164. <?php include_once($dir."/help.php")?></div>

Documentation generated on Thu, 03 May 2012 15:05:59 +0200 by phpDocumentor 1.4.1