fix a bug wrt xorg_errors
[platal.git] / templates / search.tpl
1 {**************************************************************************}
2 {*                                                                        *}
3 {*  Copyright (C) 2003-2004 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 !$advanced}
26   {include file='search.quick.form.tpl' show_js=1}
27   {else}
28   {include file=search.adv.links.tpl do_title=1 with_soundex=$with_soundex}
29   {/if}
30
31   <h1 class='right'>
32     {if $search_results_nb==0}Aucune{else}{$search_results_nb}{/if} réponse{if $search_results_nb>1}s{/if}.
33   </h1>
34
35   {if $search_results_nb > 1}
36   <div>
37     Trier par :
38     {foreach from=$search_order_link item=tri}
39     [<a href='{$tri.url}'>
40     {if $tri.asc or $tri.desc}<strong>{/if}
41     {$tri.text}
42     {if $tri.desc}<img src='{rel}/images/up.png' alt='tri ascendant' />{/if}
43     {if  $tri.asc}<img src='{rel}/images/dn.png' alt='tri descendant' />{/if}
44     {if $tri.asc or $tri.desc}</strong>{/if}
45     </a>]
46     {/foreach}
47   </div>
48   {/if}
49
50   {if $search_results_nb}
51   <div class="contact-list" style="clear:both">
52     {capture name=list}
53     {iterate item=res from=$search_results}
54       {if $res.contact || $res.watch}
55         {include file=include/minifiche.tpl c=$res show_action="retirer"}
56       {else}
57         {include file=include/minifiche.tpl c=$res show_action="ajouter"}
58       {/if}
59     {/iterate}
60     {/capture}
61     {$smarty.capture.list|smarty:nodefaults}
62   </div>
63
64   {if $search_pages_nb > 1}
65   <p>
66     {foreach from=$search_pages_link item=l}
67     {if $l.i eq $search_page}
68     <span class="erreur">{$l.text}</span>
69     {else}
70     <a href="{$l.u}">{$l.text}</a>
71     {/if}
72     {/foreach}
73   </p>
74   {/if}
75   {/if}
76
77   {min_auth level='cookie'}
78   <br />
79   {if $smarty.capture.list|smarty:nodefaults|display_lines > 20}
80   {if $advanced}
81   {include file=search.adv.links.tpl do_title=1}
82   {else}
83   {include file='search.quick.form.tpl'}
84   {/if}
85   {/if}
86   
87   <p>
88   <strong>Astuce:</strong>
89   Si tu survoles une fiche, tu sauras quand elle a été mise à jour la dernière fois !</p>
90   {/min_auth}
91 {else}
92   {if $advanced}
93   {include file="search.adv.form.tpl"}
94   {else}
95   {include file="search.quick.tpl"}
96   {/if}
97 {/if}
98
99
100 {* vim:set et sw=2 sts=2 sws=2: *}