{**************************************************************************}
{* *}
-{* Copyright (C) 2003-2006 Polytechnique.org *}
+{* Copyright (C) 2003-2011 Polytechnique.org *}
{* http://opensource.polytechnique.org/ *}
{* *}
{* This program is free software; you can redistribute it and/or modify *}
{* *}
{**************************************************************************}
-<h1>Recherche simple dans l'annuaire</h1>
+<h1>Recherche dans l'annuaire</h1>
-<form action="{rel}/search" method="get"{if $show_js} id="quick_form"{/if}>
- <table class="bicol" cellspacing="0" cellpadding="4">
- <tr>
- <td style="width: 78%">
- <input type='text' name="quick" value="{$smarty.request.quick}" style="width: 100%" /><br />
- {min_auth level='cookie'}
- <input type='checkbox' name='order' value='date_mod' {if $smarty.request.order eq "date_mod"}checked='checked'{/if} />
- mettre les fiches modifiées récemment en premier
- {if $smarty.request.nonins}
- <br /><input type='checkbox' name='nonins' readonly="readonly" checked='checked' value='1' /> Chercher uniquement des non inscrits
- {/if}
- {/min_auth}
+<form action="search" method="get"{if $show_js} id="quick_form"{/if}>
+ {if $smarty.session.auth ge AUTH_COOKIE}
+ <fieldset>
+ <legend>{icon name=magnifier} Recherche simple</legend>
+
+ <table style="width: 100%">
+ <tr>
+ <td colspan="2">
+ <input type='text' name="quick" value="{$smarty.request.quick}" style="width: 98%" /><br />
+ </td>
+ </tr>
+ <tr class="noprint">
+ <td style="width: 70%">
+ <input type="checkbox" name="with_soundex" id="with_soundex" value="1" {if $smarty.request.with_soundex}checked="checked"{/if} /> <label for="with_soundex">Activer la recherche par proximité sonore.</label>
+ <br /><input type='checkbox' name='order' id="order" value='date_mod' {if $smarty.request.order eq "date_mod"}checked='checked'{/if} /> <label for="order">Mettre les fiches modifiées récemment en premier.</label>
+ <br /><input type='checkbox' name='nonins' id="nonins" {if $smarty.request.nonins}checked='checked'{/if} value='1' /> <label for="nonins">Chercher uniquement des non inscrits.</label>
+ </td>
+ <td class="right">
+ <br /><input type="submit" value="Chercher" />
+ </td>
+ </tr>
+ </table>
+ <hr />
+ <div class="center">
+ <a href="search/adv">Effectuer une recherche avancée</a>
+ </div>
+ </fieldset>
+ {else}
+ <table style="width: 100%">
+ <tr class="noprint">
+ <td style="width: 60%">
+ <input type='text' name="quick" value="{$smarty.request.quick}" style="width: 98%" /><br />
</td>
- <td>
+ <td class="right">
<input type="submit" value="Chercher" />
- {min_auth level="cookie"}
- <br /><a class='smaller' href="{rel}/search/adv">Recherche avancée</a>
- {/min_auth}
</td>
</tr>
</table>
+ {/if}
</form>
-<br />
-
{if $show_js}
{literal}
<script type="text/javascript">
- <!--
- // Activate the first search input field.
- document.getElementById("quick_form").quick.focus();
- // -->
+ $(function() {
+ $("#quick_form input[name='quick']").focus();
+ });
</script>
{/literal}
{/if}
-{* vim:set et sw=2 sts=2 sws=2: *}
+{* vim:set et sw=2 sts=2 sws=2 enc=utf-8: *}