Commit | Line | Data |
---|---|---|
f1fd3e35 NI |
1 | {**************************************************************************} |
2 | {* *} | |
3 | {* Copyright (C) 2003-2013 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 | {config_load file="mails.conf" section="mails_comletter"} | |
24 | {if $mail_part eq 'head'} | |
25 | {from full=#from#} | |
26 | {subject text=$issue->title(true)} | |
27 | {if isset(#replyto#)}{add_header name='Reply-To' value=#replyto#}{/if} | |
28 | {if isset(#retpath#)}{add_header name='Return-Path' value=#retpath#}{/if} | |
29 | {elseif $mail_part eq 'text'} | |
30 | {if !$is_mail} | |
31 | <pre style="width : 72ex; margin: auto"> | |
32 | {/if} | |
33 | ==================================================================== | |
34 | {$issue->title()} | |
35 | ==================================================================== | |
36 | ||
37 | {$issue->head($user, 'text')} | |
38 | ||
39 | ||
40 | {foreach from=$issue->arts key=cid item=arts name=cats} | |
41 | {$smarty.foreach.cats.iteration} *{$issue->category($cid)}* | |
42 | {foreach from=$arts item=art} | |
43 | - {$art->title()} | |
44 | {/foreach} | |
45 | ||
46 | {/foreach} | |
47 | ||
48 | {foreach from=$issue->arts key=cid item=arts} | |
49 | -------------------------------------------------------------------- | |
50 | *{$issue->category($cid)}* | |
51 | -------------------------------------------------------------------- | |
52 | ||
53 | {foreach from=$arts item=art} | |
54 | {$art->toText($hash, $user->login())} | |
55 | ||
56 | {/foreach} | |
57 | {/foreach} | |
58 | ||
59 | {$issue->signature('text')} | |
60 | ||
61 | -------------------------------------------------------------------- | |
62 | Cette lettre est envoyée à tous les Polytechniciens sur Internet par | |
63 | l'intermédiaire de Polytechnique.org. | |
64 | ||
65 | {if $is_mail} | |
66 | archives : <https://www.polytechnique.org/comletter> | |
67 | écrire : <https://www.polytechnique.org/comletter/submit> | |
68 | ne plus recevoir : <https://www.polytechnique.org/comletter/out/{if $hash}{$hash}{else}nohash{/if}/{$issue->id}> | |
69 | {else} | |
70 | archives : <https://www.polytechnique.org/comletter> | |
71 | écrire : <https://www.polytechnique.org/comletter/submit> | |
72 | ne plus recevoir : <https://www.polytechnique.org/comletter/out/{if $hash}{$hash}{else}nohash{/if}/{$issue->id}> | |
73 | {/if} | |
74 | {if !$is_mail} | |
75 | </pre> | |
76 | {/if} | |
77 | {elseif $mail_part eq 'html'} | |
78 | {if $is_mail} | |
79 | <?xml version="1.0" encoding="UTF-8"?> | |
80 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> | |
81 | <html xmlns="http://www.w3.org/1999/xhtml"> | |
82 | <head> | |
83 | <title>{$nl->name}</title> | |
84 | <style type="text/css"> | |
85 | {literal} | |
86 | body { background-color: #ddd; color: #000; } | |
87 | {/literal} | |
88 | <!-- | |
89 | {$issue->css()} | |
90 | --> | |
91 | </style> | |
92 | </head> | |
93 | <body> | |
94 | <div class='nl_background'> | |
95 | {/if} | |
96 | <div class='nl'> | |
97 | <div class="title"><a href="{$globals->baseurl}">{$issue->title()}</a></div> | |
98 | <div class="intro">{$issue->head($user, 'html')|smarty:nodefaults}</div> | |
99 | <a id="top_lnk"></a> | |
100 | {foreach from=$issue->arts key=cid item=arts name=cats} | |
101 | <div class="lnk"> | |
102 | <a href="{$prefix}#cat{$cid}"><strong>{$smarty.foreach.cats.iteration}. {$issue->category($cid)}</strong></a><br /> | |
103 | {foreach from=$arts item=art} | |
104 | <a href="{$prefix}#art{$art->aid}"> - {$art->title()}</a><br /> | |
105 | {/foreach} | |
106 | </div> | |
107 | {/foreach} | |
108 | ||
109 | {foreach from=$issue->arts key=cid item=arts name=cats} | |
110 | <h1 class="xorg_nl"><a id="cat{$cid}"></a> | |
111 | {$issue->category($cid)} | |
112 | </h1> | |
113 | {foreach from=$arts item=art} | |
114 | {$art->toHtml($hash, $user->login())|smarty:nodefaults} | |
115 | <div class="top_lnk"><a href="{$prefix}#top_lnk">Revenir au sommaire</a></div> | |
116 | {/foreach} | |
117 | {/foreach} | |
118 | <div class="signature">{$issue->signature('html')|smarty:nodefaults}</div> | |
119 | <div class="foot1"> | |
120 | Cette lettre est envoyée à tous les Polytechniciens sur Internet par l'intermédiaire de Polytechnique.org. | |
121 | </div> | |
122 | <div class="foot2"> | |
123 | [<a href="https://www.polytechnique.org/comletter">archives</a> | | |
124 | <a href="https://www.polytechnique.org/comletter/submit">écrire dans la NL</a> | | |
125 | <a href="https://www.polytechnique.org/comletter/out/nohash/{$issue->id}">ne plus recevoir</a>] | |
126 | </div> | |
127 | </div> | |
128 | {if $is_mail} | |
129 | </div> | |
130 | </body> | |
131 | </html> | |
132 | {/if} | |
133 | {/if} | |
134 | ||
135 | {* vim:set et sw=2 sts=2 sws=2 enc=utf-8: *} |