source: products/quintagroup.plonecaptchas/trunk/quintagroup/plonecaptchas/skins/captchas_join_form/join_form.cpt @ 1691

Last change on this file since 1691 was 1691, checked in by liebster, 14 years ago

Fixed global definitions in templates by Plone4

File size: 8.6 KB
Line 
1<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
2      xmlns:tal="http://xml.zope.org/namespaces/tal"
3      xmlns:metal="http://xml.zope.org/namespaces/metal"
4      xmlns:i18n="http://xml.zope.org/namespaces/i18n"
5      lang="en"
6      metal:use-macro="here/main_template/macros/master"
7      i18n:domain="plone">
8
9<head>
10    <metal:block fill-slot="top_slot"
11                 tal:define="dummy python:request.set('disable_border',1)" />
12    <metal:block fill-slot="column_one_slot" />
13    <metal:block fill-slot="column_two_slot" />
14</head>
15
16<body>
17
18<div metal:fill-slot="main"
19     tal:define="template_id template/getId;
20                 errors options/state/getErrors;
21                 mailhost context/MailHost/smtp_host|nothing;
22                 mailfrom context/email_from_address|nothing;
23                 site_properties context/portal_properties/site_properties;
24                 allowEnterPassword not:utool/getPortalObject/validate_email|nothing;
25                 mailpw site_properties/validate_email;
26                 mailconfigured python:allowEnterPassword or (mailhost and mailfrom)">
27
28  <h1 class="documentFirstHeading"
29      i18n:translate="heading_registration_form">Registration Form</h1>
30
31
32  <div tal:condition="not:mailconfigured">
33    <p i18n:translate="no_join_without_configured_mail">
34      This site has not configured its email settings. Until email has
35      been configured it is not possible to create an account.
36    </p>
37  </div>
38  <form action=""
39        class="enableAutoFocus enableUnloadProtection"
40        method="post"
41        tal:condition="mailconfigured"
42        tal:define="allowEnterPassword site_properties/validate_email|nothing;"
43        tal:attributes="action template_id" >
44
45    <fieldset>
46
47      <legend i18n:translate="legend_personal_details">
48          Personal Details
49      </legend>
50
51      <input type="hidden" name="came_from" value=""
52             tal:condition="request/came_from|nothing"
53             tal:attributes="value request/came_from" />
54      <input type="hidden" name="last_visit:date" value="ZopeTime"
55             tal:attributes="value here/ZopeTime" />
56      <input type="hidden" name="prev_visit:date" value="ZopeTime"
57             tal:attributes="value here/ZopeTime" />
58      <input type="hidden" name="came_from_prefs" value=""
59             tal:attributes="value request/came_from_prefs|nothing" />
60
61      <div class="row"
62           tal:define="error errors/fullname| nothing;
63                       fullname request/fullname | nothing;"
64           tal:attributes="class python:test(error, 'field error', 'field')">
65
66        <label for="fullname"
67               i18n:translate="label_full_name">Full Name</label>
68
69        <div class="formHelp" i18n:translate="help_full_name_creation">
70          Enter full name, eg. John Smith.
71        </div>
72
73        <div tal:content="error">Validation error output</div>
74
75        <input type="text"
76               name="fullname"
77               id="fullname"
78               size="30"
79               value="fullname"
80               tal:attributes="value fullname;"
81               />
82
83      </div>
84
85      <div class="field"
86           tal:define="error errors/username| nothing;
87                       username request/username | nothing;"
88           tal:attributes="class python:test(error, 'field error', 'field')">
89
90        <label for="username"
91               i18n:translate="label_user_name">User Name</label>
92
93        <span class="fieldRequired" title="Required"
94              i18n:attributes="title title_required;"
95              i18n:translate="label_required">(Required)</span>
96
97              <div i18n:translate="help_user_name_creation_casesensitive"
98                   class="formHelp">
99                Enter a user name, usually something like
100                'jsmith'. No spaces or special characters.
101                Usernames and passwords are case sensitive,
102                make sure the caps lock key is not enabled.
103                This is the name used to log in.
104              </div>
105
106              <div tal:content="error">Validation error output</div>
107
108              <input type="text"
109                     name="username"
110                     id="username"
111                     size="30"
112                     value="username"
113                     tal:attributes="value username;"
114                     />
115      </div>
116
117      <div class="field"
118           tal:define="error errors/email | nothing;
119                       email request/email | nothing;"
120           tal:attributes="class python:test(error, 'field error', 'field')">
121
122        <label for="email"
123               i18n:translate="label_email">E-mail</label>
124
125        <span class="fieldRequired" title="Required"
126              i18n:attributes="title title_required;"
127              i18n:translate="label_required">(Required)</span>
128
129              <div class="formHelp" i18n:translate="help_email_creation">
130                Enter an email address. This is necessary in case the password
131                is lost. We respect your privacy, and will not give the address
132                away to any third parties or expose it anywhere.
133              </div>
134
135              <div tal:content="error">Validation error output</div>
136
137              <input type="text"
138                     name="email"
139                     id="email"
140                     size="30"
141                     tal:attributes="value email;"
142                     />
143      </div>
144
145
146      <div class="field"
147           tal:condition="not: allowEnterPassword"
148           tal:define="error errors/password | nothing;
149                       password request/password | nothing;"
150           tal:attributes="class python:test(error, 'field error', 'field')">
151
152        <label for="password"
153               i18n:translate="label_password">Password</label>
154
155        <span class="fieldRequired" title="Required"
156              i18n:attributes="title title_required;"
157              i18n:translate="label_required">(Required)</span>
158
159              <div class="formHelp" i18n:translate="help_password_creation">
160                Minimum 5 characters.
161              </div>
162
163              <div tal:content="error">Validation error output</div>
164
165              <input type="password"
166                     name="password"
167                     id="password"
168                     size="10"
169                     value=""
170                     />
171      </div>
172
173      <div class="field"
174           tal:condition="not: allowEnterPassword"
175           tal:define="error errors/password_confirm | nothing;
176                       password_confirm request/password_confirm | nothing;"
177           tal:attributes="class python:test(error, 'field error', 'field')">
178
179
180        <label for="password_confirm"
181               i18n:translate="label_confirm_password">Confirm password</label>
182
183        <span class="fieldRequired" title="Required"
184              i18n:attributes="title title_required;"
185              i18n:translate="label_required">(Required)</span>
186
187              <div class="formHelp" i18n:translate="help_confirm_password">
188                Re-enter the password. Make sure the passwords are identical.
189              </div>
190
191              <div tal:content="error">Validation error output</div>
192
193              <input type="password"
194                     name="password_confirm"
195                     id="password_confirm"
196                     size="10"
197                     value=""
198                     />
199      </div>
200
201      <div class="field"
202           tal:condition="not: allowEnterPassword"
203           tal:define="mail_me request/mail_me|nothing">
204
205        <input type="checkbox"
206               class="noborder"
207               name="mail_me"
208               size="30"
209               id="cb_mailme"
210               tal:attributes="checked python:test(mail_me, 'checked', None);"
211               />
212        <label for="cb_mailme" i18n:translate="label_mail_password">Send a mail with the password</label>
213      </div>
214
215      <div class="field"
216           tal:condition="allowEnterPassword">
217
218        <div class="formHelp" i18n:translate="label_password_change_mail">
219          A URL will be generated and e-mailed to you; follow the link
220          to reach a page where you can change your password and
221          complete the registration process.
222        </div>
223      </div>
224      <div metal:use-macro="here/captcha_widget/macros/captcha"></div>
225      <div class="formControls">
226        <input class="context"
227               type="submit"
228               name="form.button.Register"
229               value="Register"
230               i18n:attributes="value label_register;" />
231      </div>
232
233    </fieldset>
234
235    <input type="hidden" name="form.submitted" value="1" />
236
237    <input tal:replace="structure context/@@authenticator/authenticator|nothing" />
238
239  </form>
240</div>
241
242</body>
243</html>
Note: See TracBrowser for help on using the repository browser.