0
|
1 <macro name="mailing_list_archive_settings" requires="servlet">
|
|
2 <n.node_page.>
|
|
3 <n.if.not.visitor.can_edit.page_node>
|
|
4 <then>
|
|
5 <n.login.><t>Only authorized users can proceed in this area.</t></n.login.>
|
|
6 </then>
|
|
7 </n.if.not.visitor.can_edit.page_node>
|
|
8
|
|
9 <n.page_node.get_this_mailing_list_archive.>
|
|
10 <n.if.not.is_submitted_form>
|
|
11 <then.fill_in_mailing_list_archive_fields/>
|
|
12 <else>
|
|
13 <n.if.is_remove_mailing_list_archive_settings>
|
|
14 <then.remove_mailing_list_archive_settings_and_redirect/>
|
|
15 <else.save_mailing_list_archive_settings_and_redirect/>
|
|
16 </n.if.is_remove_mailing_list_archive_settings>
|
|
17 </else>
|
|
18 </n.if.not.is_submitted_form>
|
|
19
|
|
20 <n.html>
|
|
21 <head>
|
|
22 <META NAME="robots" CONTENT="noindex,nofollow"/>
|
|
23 <n.title.><t>Mailing List Archive Settings</t></n.title.>
|
|
24 <n.mailing_list_address_field.focus/>
|
|
25 <style type="text/css">
|
|
26 div.field-title { margin-top: 0; }
|
|
27 div.tip { font-size:80%; margin-top:.4em; }
|
|
28 </style>
|
|
29 <script type="text/javascript">
|
|
30 $(document).ready(function() {
|
|
31 $('form').submit(function() {
|
|
32 var action = $('#action').val();
|
|
33 if (action == 'remove')
|
|
34 return confirm('<t>Do you really want to remove the mailing list archive settings?</t>');
|
|
35 return true;
|
|
36 });
|
|
37 });
|
|
38 </script>
|
|
39 </head>
|
|
40 <body>
|
|
41 <n.edit_header first_text="[n.page_node.get_app_node.subject/]" second_text="[t]Mailing List Archive Settings[/t]" />
|
|
42
|
|
43 <n.if.is_submitted_form>
|
|
44 <then.show_mailing_list_error/>
|
|
45 </n.if.is_submitted_form>
|
|
46
|
|
47 <n.form.>
|
|
48 <input id="action" type="hidden" name="action" value="save"/>
|
|
49 <n.mailing_list_address_group/>
|
|
50 <n.mailing_list_website_group/>
|
|
51 <n.mailing_list_server_group/>
|
|
52 <n.mailing_list_subject_prefix_group/>
|
|
53 <n.mailing_list_other_settings_group/>
|
|
54
|
|
55 <input type="submit" class="toolbar action-button" value="[t]Save Settings[/t]" onclick="$('#action').val('save')"/>
|
|
56 <input type="submit" class="toolbar action-button" value="[t]Remove Settings[/t]" onclick="$('#action').val('remove')"/>
|
|
57 <t>or</t> <a href="[n.page_node.url /]"><t>Cancel</t></a>
|
|
58 </n.form.>
|
|
59 </body>
|
|
60 </n.html>
|
|
61 </n.page_node.get_this_mailing_list_archive.>
|
|
62 </n.node_page.>
|
|
63 </macro>
|
|
64
|
|
65 <macro name="fill_in_mailing_list_archive_fields" requires="mailing_list">
|
|
66 <n.if.page_node.is_a_mailing_list_archive>
|
|
67 <then>
|
|
68 <n.mailing_list_address_field.set_value value="[n.mailing_list_address/]" />
|
|
69 <n.mailing_list_url_field.set_value value="[n.mailing_list_url/]" />
|
|
70 <n.mailing_list_server_field.set_value value="[n.mailing_list_server/]" />
|
|
71 <n.mailing_list_prefix_field.set_value value="[n.mailing_list_prefix/]" />
|
|
72 <n.plain_text_only_field.set_value value="[n.plain_text_only/]" />
|
|
73 <n.ignore_xnoarchive_field.set_value value="[n.ignore_xnoarchive/]" />
|
|
74 </then>
|
|
75 <else>
|
|
76 <n.mailing_list_server_field.set_value value="unknown" />
|
|
77 </else>
|
|
78 </n.if.page_node.is_a_mailing_list_archive>
|
|
79 </macro>
|
|
80
|
|
81 <macro name="remove_mailing_list_archive_settings_and_redirect" requires="mailing_list, node_page">
|
|
82 <n.catch_exception. id="save-block">
|
|
83 <n.remove/>
|
|
84 <n.redirect_to.page_node.url/>
|
|
85 </n.catch_exception.>
|
|
86 </macro>
|
|
87
|
|
88 <macro name="save_mailing_list_archive_settings_and_redirect" requires="mailing_list, node_page">
|
|
89 <n.catch_exception. id="save-block">
|
|
90 <n.set_var. name="is-new">
|
|
91 <n.if.page_node.is_a_mailing_list_archive>
|
|
92 <then>no</then>
|
|
93 <else>yes</else>
|
|
94 </n.if.page_node.is_a_mailing_list_archive>
|
|
95 </n.set_var.>
|
|
96 <n.save>
|
|
97 <address><n.mailing_list_address_field.value/></address>
|
|
98 <url><n.mailing_list_url_field.value/></url>
|
|
99 <server><n.mailing_list_server_field.value/></server>
|
|
100 <prefix><n.mailing_list_prefix_field.value/></prefix>
|
|
101 <plain_text_only><n.plain_text_only_field.value/></plain_text_only>
|
|
102 <ignore_xnoarchive><n.ignore_xnoarchive_field.value/></ignore_xnoarchive>
|
|
103 <do>
|
|
104 </do>
|
|
105 </n.save>
|
|
106 <n.if.equal value1="[n.var name='is-new'/]" value2="yes">
|
|
107 <then.redirect_to.page_node.subscription_instructions_path/>
|
|
108 <else.redirect_to.page_node.url/>
|
|
109 </n.if.equal>
|
|
110 </n.catch_exception.>
|
|
111 </macro>
|
|
112
|
|
113 <macro name="mailing_list_address_group" requires="mailing_list">
|
|
114 <div class="field-box light-border-color">
|
|
115 <div class="second-font field-title"><t>Mailing List Address</t> <span class="important">*</span></div>
|
|
116 <div class="weak-color">
|
|
117 <n.mailing_list_address_field.input size="40" />
|
|
118 </div>
|
|
119 <div class="weak-color tip">
|
|
120 <t>Example: listname@listdomain.com</t>
|
|
121 </div>
|
|
122
|
|
123 <n.if.page_node.is_a_mailing_list_archive>
|
|
124 <then>
|
|
125 <div class="shaded-bg-color rounded" style="padding: .6em .5em;margin:.4em 0 0">
|
|
126 <div style="float:left;height:2em;margin-right:.5em">
|
|
127 <img src="/images/tool_big.png" width="27" height="27"/>
|
|
128 </div>
|
|
129 <div style="margin-left:.5em">
|
|
130 <t><b>IMPORTANT</b>: You must subscribe this archive to the mailing list in order to make it work.</t><br/>
|
|
131 <div style="margin-top:.3em">
|
|
132 <t>Please follow the <n.subscribe_instructions_link.>subscription instructions</n.subscribe_instructions_link.> for this archive.</t>
|
|
133 </div>
|
|
134 </div>
|
|
135 </div>
|
|
136 </then>
|
|
137 </n.if.page_node.is_a_mailing_list_archive>
|
|
138 </div>
|
|
139 </macro>
|
|
140
|
|
141 <macro name="mailing_list_website_group" requires="mailing_list">
|
|
142 <div class="field-box light-border-color">
|
|
143 <div class="second-font field-title"><t>Mailing List Website</t> <span class="important">*</span></div>
|
|
144 <div class="weak-color">
|
|
145 <t>Enter the homepage of this mailing list, where users can find more information.</t><br/>
|
|
146 <n.mailing_list_url_field.input size="72" />
|
|
147 </div>
|
|
148 </div>
|
|
149 </macro>
|
|
150
|
|
151 <macro name="mailing_list_server_group" requires="mailing_list">
|
|
152 <div class="field-box light-border-color">
|
|
153 <div class="second-font field-title"><t>List Server</t></div>
|
|
154 <div class="weak-color">
|
|
155 <t>If you know, please select the mailing list server application and its version.</t><br/>
|
|
156 <n.mailing_list_server_field.select.>
|
|
157 <n.available_servers.loop.>
|
|
158 <n.set_var. name='server_name'>
|
|
159 <n.if.equal value1="[n.current_server_name/]" value2="Unknown or Other">
|
|
160 <then><t>Unknown or Other</t></then>
|
|
161 <else><n.current_server_name/></else>
|
|
162 </n.if.equal>
|
|
163 </n.set_var.>
|
|
164 <n.select_option value="[n.current_server/]" selectedValue="[n.mailing_list_server_field.value/]" text="[n.var name='server_name'/]"/>
|
|
165 </n.available_servers.loop.>
|
|
166 </n.mailing_list_server_field.select.>
|
|
167 </div>
|
|
168 </div>
|
|
169 </macro>
|
|
170
|
|
171 <macro name="mailing_list_subject_prefix_group" requires="mailing_list">
|
|
172 <div class="field-box light-border-color">
|
|
173 <div class="second-font field-title"><t>Subject Prefix</t></div>
|
|
174 <div class="weak-color">
|
|
175 <t>Enter the prefix that this mailing list uses before the subject.
|
|
176 The prefix will be automatically removed from the imported emails.</t>
|
|
177 <br/>
|
|
178 <n.mailing_list_prefix_field.input size="25" />
|
|
179 <div class="weak-color tip">
|
|
180 <t>Examples: '[the-list]', 'Abc:', etc.</t>
|
|
181 </div>
|
|
182 </div>
|
|
183 </div>
|
|
184 </macro>
|
|
185
|
|
186 <macro name="mailing_list_other_settings_group" requires="mailing_list">
|
|
187 <div class="field-box light-border-color">
|
|
188 <div class="second-font field-title"><t>Other Settings</t></div>
|
|
189 <table>
|
|
190 <tr>
|
|
191 <td><n.plain_text_only_field.checkbox /></td>
|
|
192 <td><label for="[n.plain_text_only_field.name/]"><t>This list accepts only plain-text emails</t></label></td>
|
|
193 </tr>
|
|
194 <tr style="vertical-align:top">
|
|
195 <td><n.ignore_xnoarchive_field.checkbox /></td>
|
|
196 <td style="padding-top:.2em">
|
|
197 <label for="[n.ignore_xnoarchive_field.name/]"><t>Ignore X-No-Archive header</t></label>
|
|
198 <div class="weak-color tip"><t>TIP: If your archive is subscribed to the mailing list and it is still not working, you may try ignoring the X-No-Archive header.</t></div>
|
|
199 </td>
|
|
200 </tr>
|
|
201 </table>
|
|
202 </div>
|
|
203 </macro>
|
|
204
|
|
205 <macro name="subscribe_instructions_link" dot_parameter="text" requires="node_page">
|
|
206 <a href="[n.page_node.subscription_instructions_path/]"><n.text/></a>
|
|
207 </macro>
|
|
208
|
|
209 <macro name="mailing_list_address_field" dot_parameter="do">
|
|
210 <n.field. name="mailing_list_address"><n.do/></n.field.>
|
|
211 </macro>
|
|
212
|
|
213 <macro name="mailing_list_url_field" dot_parameter="do">
|
|
214 <n.field. name="mailing_list_url"><n.do/></n.field.>
|
|
215 </macro>
|
|
216
|
|
217 <macro name="mailing_list_server_field" dot_parameter="do">
|
|
218 <n.field. name="mailing_list_server"><n.do/></n.field.>
|
|
219 </macro>
|
|
220
|
|
221 <macro name="mailing_list_prefix_field" dot_parameter="do">
|
|
222 <n.field. name="mailing_list_prefix"><n.do/></n.field.>
|
|
223 </macro>
|
|
224
|
|
225 <macro name="plain_text_only_field" dot_parameter="do">
|
|
226 <n.field. name="plain_text_only"><n.do/></n.field.>
|
|
227 </macro>
|
|
228
|
|
229 <macro name="ignore_xnoarchive_field" dot_parameter="do">
|
|
230 <n.field. name="ignore_xnoarchive"><n.do/></n.field.>
|
|
231 </macro>
|
|
232
|
|
233 <macro name="show_mailing_list_error">
|
|
234 <n.format_error.handle_exception. for="save-block">
|
|
235 <n.exception. name="invalid_list_address">
|
|
236 <t>You must enter a valid email address for this mailing list.</t>
|
|
237 </n.exception.>
|
|
238 <n.exception. name="invalid_list_url">
|
|
239 <t>You must enter a valid website URL for this mailing list.</t>
|
|
240 </n.exception.>
|
|
241 </n.format_error.handle_exception.>
|
|
242 </macro>
|
|
243
|
|
244 <macro name="is_remove_mailing_list_archive_settings">
|
|
245 <n.equal value1="[n.get_parameter name='action'/]" value2="remove"/>
|
|
246 </macro>
|