780fec8dd302c4a483a0773a77d5c57438ca68b1
[platal.git] / templates / search / index.tpl
1 {**************************************************************************}
2 {*                                                                        *}
3 {*  Copyright (C) 2003-2006 Polytechnique.org                             *}
4 {*  http://opensource.polytechnique.org/                                  *}
5 {*                                                                        *}
6 {*  This program is free software; you can redistribute it and/or modify  *}
7 {*  it under the terms of the GNU General Public License as published by  *}
8 {*  the Free Software Foundation; either version 2 of the License, or     *}
9 {*  (at your option) any later version.                                   *}
10 {*                                                                        *}
11 {*  This program is distributed in the hope that it will be useful,       *}
12 {*  but WITHOUT ANY WARRANTY; without even the implied warranty of        *}
13 {*  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *}
14 {*  GNU General Public License for more details.                          *}
15 {*                                                                        *}
16 {*  You should have received a copy of the GNU General Public License     *}
17 {*  along with this program; if not, write to the Free Software           *}
18 {*  Foundation, Inc.,                                                     *}
19 {*  59 Temple Place, Suite 330, Boston, MA  02111-1307  USA               *}
20 {*                                                                        *}
21 {**************************************************************************}
22
23
24 {if $formulaire==0 and !$xorg_errors|count}
25   {if !$simple}
26     {if !$advanced}
27     {include file=search/quick.form.tpl show_js=1}
28     {else}
29     {include file=search/adv.links.tpl do_title=1 with_soundex=$with_soundex}
30     {/if}
31   {/if}
32
33   {if $search_results_nb == 0 or ($advanced and !$simple)}
34   <h1 class='right'>
35     {if $search_results_nb==0}Aucune{else}{$search_results_nb}{/if} réponse{if $search_results_nb>1}s{/if}
36     {if $search_results_nb and $advanced and !$simple}
37     <span class="noprint">
38     &nbsp;(<a href='geoloc/?{$search_vars}'>Voir sur une carte</a>)
39     </span>
40     {/if}
41   </h1>
42   {/if}
43   
44   {if $search_results_nb > 1}
45   <div class="noprint">
46     Trier par :
47     {foreach from=$search_order_link item=tri}
48     [<a href='{$tri.url}'>
49     {if $tri.asc or $tri.desc}<strong>{/if}
50     {$tri.text}
51     {if $tri.desc}<img src='images/up.png' alt='tri ascendant' />{/if}
52     {if  $tri.asc}<img src='images/dn.png' alt='tri descendant' />{/if}
53     {if $tri.asc or $tri.desc}</strong>{/if}
54     </a>]
55     {/foreach}
56   </div>
57   {/if}
58
59   {if $search_results_nb}
60   <div class="contact-list" style="clear:both">
61     {capture name=list}
62     {iterate item=res from=$search_results}
63       {if $res.contact || $res.watch}
64         {include file=include/minifiche.tpl c=$res show_action="retirer"}
65       {else}
66         {include file=include/minifiche.tpl c=$res show_action="ajouter"}
67       {/if}
68     {/iterate}
69     {/capture}
70     {$smarty.capture.list|smarty:nodefaults}
71   </div>
72
73   {if $search_pages_nb > 1}
74   <p>
75     {foreach from=$search_pages_link item=l}
76     {if $l.i eq $search_page}
77     <span class="erreur">{$l.text}</span>
78     {else}
79     <a href="{$l.u}">{$l.text}</a>
80     {/if}
81     {/foreach}
82   </p>
83   {/if}
84   {/if}
85
86   {if $smarty.session.auth ge AUTH_COOKIE}
87   <br />
88   {if $smarty.capture.list|smarty:nodefaults|display_lines > 20}
89   <div class="noprint">
90   {if $advanced}
91   {include file=search/adv.links.tpl do_title=1}
92   {else}
93   {include file=search/quick.form.tpl}
94   {/if}
95   </div>
96   {/if}
97   
98   <p class="noprint">
99   <strong>Astuce:</strong>
100   Si tu survoles une fiche, tu sauras quand elle a été mise à jour la dernière fois !</p>
101   {/if}
102 {else}
103   {if $advanced}
104   {include file=search/adv.form.tpl}
105   {else}
106   {include file=search/quick.tpl}
107   {/if}
108 {/if}
109
110
111 {* vim:set et sw=2 sts=2 sws=2: *}