Adds XSRF protection to the AXLetter module.
[platal.git] / templates / newsletter / show.tpl
index a681ec9..7b162ca 100644 (file)
@@ -1,6 +1,6 @@
 {**************************************************************************}
 {*                                                                        *}
-{*  Copyright (C) 2003-2006 Polytechnique.org                             *}
+{*  Copyright (C) 2003-2008 Polytechnique.org                             *}
 {*  http://opensource.polytechnique.org/                                  *}
 {*                                                                        *}
 {*  This program is free software; you can redistribute it and/or modify  *}
 {*                                                                        *}
 {**************************************************************************}
 
-<h1>
+<h1 style="clear: both">
   Lettre de Polytechnique.org du {$nl->_date|date_format}
 </h1>
 
-<p>
-[<a href='nl'>liste des lettres</a>]
-{if $smarty.get.text}
-[<a href='nl/show/{$nl->id()}'>version HTML</a>]
-{else}
-[<a href='nl/show/{$nl->id()}?text=1'>version Texte</a>]
-{/if}
-{if $smarty.session.perms eq admin}
-[<a href='admin/newsletter/edit/{$nl->id()}'>Editer</a>]
-{/if}
+<p style="float: left">
+  {if $smarty.get.text}
+  [<a href='nl/show/{$nl->id()}'>version HTML</a>]
+  {else}
+  [<a href='nl/show/{$nl->id()}?text=1'>version Texte</a>]
+  {/if}
+  {if hasPerm('admin')}
+  [<a href='admin/newsletter/edit/{$nl->id()}'>Editer</a>]
+  {/if}
 </p>
 
+{include file="include/massmailer-nav.tpl" mm=$nl base=nl}
+
 <form method="post" action="{$platal->path}">
-  <div class='center'>
+  <div class='center' style="clear: both">
     <input type='submit' value="me l'envoyer" name='send' />
   </div>
 </form>
 
-<fieldset>
-<legend>{$nl->title(true)}</legend>
-  {if $smarty.get.text}
-  <pre style="width : 72ex; margin: auto">{$nl->toText($smarty.session.prenom, $smarty.session.nom, $smarty.session.femme)}
-  </pre>
-  {else}
-  <div class='nl'>
-    {$nl->toHtml($smarty.session.prenom, $smarty.session.nom, $smarty.session.femme,
-                     false, true)|smarty:nodefaults}
-  </div>
-  {/if}
-</fieldset>
+<table class="bicol">
+  <tr><th>{$nl->title(true)}</th></tr>
+  <tr>
+    <td>
+      {include file="newsletter/nl.mail.tpl" escape=true}
+    </td>
+  </tr>
+</table>
 
-{* vim:set et sw=2 sts=2 sws=2: *}
+{* vim:set et sw=2 sts=2 sws=2 enc=utf-8: *}