Mercurial > hg > vamp-website
comparison forum/Themes/default/ManageMembers.template.php @ 76:e3e11437ecea website
Add forum code
author | Chris Cannam |
---|---|
date | Sun, 07 Jul 2013 11:25:48 +0200 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
75:72f59aa7e503 | 76:e3e11437ecea |
---|---|
1 <?php | |
2 /** | |
3 * Simple Machines Forum (SMF) | |
4 * | |
5 * @package SMF | |
6 * @author Simple Machines | |
7 * @copyright 2011 Simple Machines | |
8 * @license http://www.simplemachines.org/about/smf/license.php BSD | |
9 * | |
10 * @version 2.0 | |
11 */ | |
12 | |
13 function template_search_members() | |
14 { | |
15 global $context, $settings, $options, $scripturl, $txt; | |
16 | |
17 echo ' | |
18 <div id="admincenter"> | |
19 <form action="', $scripturl, '?action=admin;area=viewmembers" method="post" accept-charset="', $context['character_set'], '"> | |
20 <div class="cat_bar"> | |
21 <h3 class="catbg"> | |
22 <span class="floatleft">', $txt['search_for'], '</span> | |
23 <span class="smalltext floatright">', $txt['wild_cards_allowed'], '</span> | |
24 </h3> | |
25 </div> | |
26 <input type="hidden" name="sa" value="query" /> | |
27 <div class="windowbg"> | |
28 <span class="topslice"><span></span></span> | |
29 <div class="content"> | |
30 <div class="flow_hidden"> | |
31 <div class="msearch_details floatleft"> | |
32 <dl class="settings right"> | |
33 <dt class="righttext"> | |
34 <strong>', $txt['member_id'], ':</strong> | |
35 <select name="types[mem_id]"> | |
36 <option value="--"><</option> | |
37 <option value="-"><=</option> | |
38 <option value="=" selected="selected">=</option> | |
39 <option value="+">>=</option> | |
40 <option value="++">></option> | |
41 </select> | |
42 </dt> | |
43 <dd> | |
44 <input type="text" name="mem_id" value="" size="6" class="input_text" /> | |
45 </dd> | |
46 <dt class="righttext"> | |
47 <strong>', $txt['age'], ':</strong> | |
48 <select name="types[age]"> | |
49 <option value="--"><</option> | |
50 <option value="-"><=</option> | |
51 <option value="=" selected="selected">=</option> | |
52 <option value="+">>=</option> | |
53 <option value="++">></option> | |
54 </select> | |
55 </dt> | |
56 <dd> | |
57 <input type="text" name="age" value="" size="6" class="input_text" /> | |
58 </dd> | |
59 <dt class="righttext"> | |
60 <strong>', $txt['member_postcount'], ':</strong> | |
61 <select name="types[posts]"> | |
62 <option value="--"><</option> | |
63 <option value="-"><=</option> | |
64 <option value="=" selected="selected">=</option> | |
65 <option value="+">>=</option> | |
66 <option value="++">></option> | |
67 </select> | |
68 </dt> | |
69 <dd> | |
70 <input type="text" name="posts" value="" size="6" class="input_text" /> | |
71 </dd> | |
72 <dt class="righttext"> | |
73 <strong>', $txt['date_registered'], ':</strong> | |
74 <select name="types[reg_date]"> | |
75 <option value="--"><</option> | |
76 <option value="-"><=</option> | |
77 <option value="=" selected="selected">=</option> | |
78 <option value="+">>=</option> | |
79 <option value="++">></option> | |
80 </select> | |
81 </dt> | |
82 <dd> | |
83 <input type="text" name="reg_date" value="" size="10" class="input_text" /><span class="smalltext">', $txt['date_format'], '</span> | |
84 </dd> | |
85 <dt class="righttext"> | |
86 <strong>', $txt['viewmembers_online'], ':</strong> | |
87 <select name="types[last_online]"> | |
88 <option value="--"><</option> | |
89 <option value="-"><=</option> | |
90 <option value="=" selected="selected">=</option> | |
91 <option value="+">>=</option> | |
92 <option value="++">></option> | |
93 </select> | |
94 </dt> | |
95 <dd> | |
96 <input type="text" name="last_online" value="" size="10" class="input_text" /><span class="smalltext">', $txt['date_format'], '</span> | |
97 </dd> | |
98 </dl> | |
99 </div> | |
100 <div class="msearch_details floatright"> | |
101 <dl class="settings right"> | |
102 <dt class="righttext"> | |
103 <strong>', $txt['username'], ':</strong> | |
104 </dt> | |
105 <dd> | |
106 <input type="text" name="membername" value="" class="input_text" /> | |
107 </dd> | |
108 <dt class="righttext"> | |
109 <strong>', $txt['email_address'], ':</strong> | |
110 </dt> | |
111 <dd> | |
112 <input type="text" name="email" value="" class="input_text" /> | |
113 </dd> | |
114 <dt class="righttext"> | |
115 <strong>', $txt['website'], ':</strong> | |
116 </dt> | |
117 <dd> | |
118 <input type="text" name="website" value="" class="input_text" /> | |
119 </dd> | |
120 <dt class="righttext"> | |
121 <strong>', $txt['location'], ':</strong> | |
122 </dt> | |
123 <dd> | |
124 <input type="text" name="location" value="" class="input_text" /> | |
125 </dd> | |
126 <dt class="righttext"> | |
127 <strong>', $txt['ip_address'], ':</strong> | |
128 </dt> | |
129 <dd> | |
130 <input type="text" name="ip" value="" class="input_text" /> | |
131 </dd> | |
132 <dt class="righttext"> | |
133 <strong>', $txt['messenger_address'], ':</strong> | |
134 </dt> | |
135 <dd> | |
136 <input type="text" name="messenger" value="" class="input_text" /> | |
137 </dd> | |
138 </dl> | |
139 </div> | |
140 </div> | |
141 <div class="flow_hidden"> | |
142 <div class="msearch_details floatleft"> | |
143 <fieldset> | |
144 <legend>', $txt['gender'], '</legend> | |
145 <label for="gender-0"><input type="checkbox" name="gender[]" value="0" id="gender-0" checked="checked" class="input_check" /> ', $txt['undefined_gender'], '</label> | |
146 <label for="gender-1"><input type="checkbox" name="gender[]" value="1" id="gender-1" checked="checked" class="input_check" /> ', $txt['male'], '</label> | |
147 <label for="gender-2"><input type="checkbox" name="gender[]" value="2" id="gender-2" checked="checked" class="input_check" /> ', $txt['female'], '</label> | |
148 </fieldset> | |
149 </div> | |
150 <div class="msearch_details floatright"> | |
151 <fieldset> | |
152 <legend>', $txt['activation_status'], '</legend> | |
153 <label for="activated-0"><input type="checkbox" name="activated[]" value="1" id="activated-0" checked="checked" class="input_check" /> ', $txt['activated'], '</label> | |
154 <label for="activated-1"><input type="checkbox" name="activated[]" value="0" id="activated-1" checked="checked" class="input_check" /> ', $txt['not_activated'], '</label> | |
155 </fieldset> | |
156 </div> | |
157 </div> | |
158 </div> | |
159 <span class="botslice clear_right"><span></span></span> | |
160 </div> | |
161 <br /> | |
162 <div class="title_bar"> | |
163 <h3 class="titlebg">', $txt['member_part_of_these_membergroups'], '</h3> | |
164 </div> | |
165 <div class="flow_hidden"> | |
166 <table width="49%" class="table_grid floatleft"> | |
167 <thead> | |
168 <tr class="catbg"> | |
169 <th scope="col" class="first_th">', $txt['membergroups'], '</th> | |
170 <th scope="col">', $txt['primary'], '</th> | |
171 <th scope="col" class="last_th">', $txt['additional'], '</th> | |
172 </tr> | |
173 </thead> | |
174 <tbody>'; | |
175 | |
176 foreach ($context['membergroups'] as $membergroup) | |
177 echo ' | |
178 <tr class="windowbg2"> | |
179 <td>', $membergroup['name'], '</td> | |
180 <td align="center"> | |
181 <input type="checkbox" name="membergroups[1][]" value="', $membergroup['id'], '" checked="checked" class="input_check" /> | |
182 </td> | |
183 <td align="center"> | |
184 ', $membergroup['can_be_additional'] ? '<input type="checkbox" name="membergroups[2][]" value="' . $membergroup['id'] . '" checked="checked" class="input_check" />' : '', ' | |
185 </td> | |
186 </tr>'; | |
187 | |
188 echo ' | |
189 <tr class="windowbg2"> | |
190 <td> | |
191 <em>', $txt['check_all'], '</em> | |
192 </td> | |
193 <td align="center"> | |
194 <input type="checkbox" onclick="invertAll(this, this.form, \'membergroups[1]\');" checked="checked" class="input_check" /> | |
195 </td> | |
196 <td align="center"> | |
197 <input type="checkbox" onclick="invertAll(this, this.form, \'membergroups[2]\');" checked="checked" class="input_check" /> | |
198 </td> | |
199 </tr> | |
200 </tbody> | |
201 </table> | |
202 | |
203 <table width="49%" class="table_grid floatright"> | |
204 <thead> | |
205 <tr class="catbg"> | |
206 <th scope="col" class="first_th"> | |
207 ', $txt['membergroups_postgroups'], ' | |
208 </th> | |
209 <th class="last_th"> </th> | |
210 </tr> | |
211 </thead> | |
212 </tbody>'; | |
213 | |
214 foreach ($context['postgroups'] as $postgroup) | |
215 echo ' | |
216 <tr class="windowbg2"> | |
217 <td> | |
218 ', $postgroup['name'], ' | |
219 </td> | |
220 <td width="40" align="center"> | |
221 <input type="checkbox" name="postgroups[]" value="', $postgroup['id'], '" checked="checked" class="input_check" /> | |
222 </td> | |
223 </tr>'; | |
224 | |
225 echo ' | |
226 <tr class="windowbg2"> | |
227 <td> | |
228 <em>', $txt['check_all'], '</em> | |
229 </td> | |
230 <td align="center"> | |
231 <input type="checkbox" onclick="invertAll(this, this.form, \'postgroups[]\');" checked="checked" class="input_check" /> | |
232 </td> | |
233 </tr> | |
234 </tbody> | |
235 </table> | |
236 </div><br /> | |
237 <div class="righttext"> | |
238 <input type="submit" value="', $txt['search'], '" class="button_submit" /> | |
239 </div> | |
240 </form> | |
241 </div> | |
242 <br class="clear" />'; | |
243 } | |
244 | |
245 function template_admin_browse() | |
246 { | |
247 global $context, $settings, $options, $scripturl, $txt, $modSettings; | |
248 | |
249 echo ' | |
250 <div id="admincenter">'; | |
251 | |
252 template_show_list('approve_list'); | |
253 | |
254 // If we have lots of outstanding members try and make the admin's life easier. | |
255 if ($context['approve_list']['total_num_items'] > 20) | |
256 { | |
257 echo ' | |
258 <br /> | |
259 <form action="', $scripturl, '?action=admin;area=viewmembers" method="post" accept-charset="', $context['character_set'], '" name="postFormOutstanding" id="postFormOutstanding" onsubmit="return onOutstandingSubmit();"> | |
260 <div class="cat_bar"> | |
261 <h3 class="catbg">', $txt['admin_browse_outstanding'], '</h3> | |
262 </div> | |
263 <script type="text/javascript"><!-- // --><![CDATA[ | |
264 function onOutstandingSubmit() | |
265 { | |
266 if (document.forms.postFormOutstanding.todo.value == "") | |
267 return; | |
268 | |
269 var message = ""; | |
270 if (document.forms.postFormOutstanding.todo.value.indexOf("delete") != -1) | |
271 message = "', $txt['admin_browse_w_delete'], '"; | |
272 else if (document.forms.postFormOutstanding.todo.value.indexOf("reject") != -1) | |
273 message = "', $txt['admin_browse_w_reject'], '"; | |
274 else if (document.forms.postFormOutstanding.todo.value == "remind") | |
275 message = "', $txt['admin_browse_w_remind'], '"; | |
276 else | |
277 message = "', $context['browse_type'] == 'approve' ? $txt['admin_browse_w_approve'] : $txt['admin_browse_w_activate'], '"; | |
278 | |
279 if (confirm(message + " ', $txt['admin_browse_outstanding_warn'], '")) | |
280 return true; | |
281 else | |
282 return false; | |
283 } | |
284 // ]]></script> | |
285 | |
286 <div class="windowbg"> | |
287 <span class="topslice"><span></span></span> | |
288 <div class="content"> | |
289 <dl class="settings"> | |
290 <dt> | |
291 ', $txt['admin_browse_outstanding_days_1'], ': | |
292 </dt> | |
293 <dd> | |
294 <input type="text" name="time_passed" value="14" maxlength="4" size="3" class="input_text" /> ', $txt['admin_browse_outstanding_days_2'], '. | |
295 </dd> | |
296 <dt> | |
297 ', $txt['admin_browse_outstanding_perform'], ': | |
298 </dt> | |
299 <dd> | |
300 <select name="todo"> | |
301 ', $context['browse_type'] == 'activate' ? ' | |
302 <option value="ok">' . $txt['admin_browse_w_activate'] . '</option>' : '', ' | |
303 <option value="okemail">', $context['browse_type'] == 'approve' ? $txt['admin_browse_w_approve'] : $txt['admin_browse_w_activate'], ' ', $txt['admin_browse_w_email'], '</option>', $context['browse_type'] == 'activate' ? '' : ' | |
304 <option value="require_activation">' . $txt['admin_browse_w_approve_require_activate'] . '</option>', ' | |
305 <option value="reject">', $txt['admin_browse_w_reject'], '</option> | |
306 <option value="rejectemail">', $txt['admin_browse_w_reject'], ' ', $txt['admin_browse_w_email'], '</option> | |
307 <option value="delete">', $txt['admin_browse_w_delete'], '</option> | |
308 <option value="deleteemail">', $txt['admin_browse_w_delete'], ' ', $txt['admin_browse_w_email'], '</option>', $context['browse_type'] == 'activate' ? ' | |
309 <option value="remind">' . $txt['admin_browse_w_remind'] . '</option>' : '', ' | |
310 </select> | |
311 </dd> | |
312 </dl> | |
313 <input type="submit" value="', $txt['admin_browse_outstanding_go'], '" class="button_submit" /> | |
314 <input type="hidden" name="type" value="', $context['browse_type'], '" /> | |
315 <input type="hidden" name="sort" value="', $context['approve_list']['sort']['id'], '" /> | |
316 <input type="hidden" name="start" value="', $context['approve_list']['start'], '" /> | |
317 <input type="hidden" name="orig_filter" value="', $context['current_filter'], '" /> | |
318 <input type="hidden" name="sa" value="approve" />', !empty($context['approve_list']['sort']['desc']) ? ' | |
319 <input type="hidden" name="desc" value="1" />' : '', ' | |
320 </div> | |
321 <span class="botslice"><span></span></span> | |
322 </div> | |
323 <input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '" /> | |
324 </form>'; | |
325 } | |
326 | |
327 echo ' | |
328 </div> | |
329 <br class="clear" />'; | |
330 } | |
331 | |
332 ?> |