PluginProbe
User Profile Builder – Beautiful User Registration Forms, User Profiles & User Role Editor / 3.9.8
User Profile Builder – Beautiful User Registration Forms, User Profiles & User Role Editor v3.9.8
4.0.3 4.0.2 4.0.1 4.0.0 3.16.6 3.16.5 3.16.4 3.16.3 3.16.2 3.16.1 3.16.0 3.15.9 3.9.9 3.9.5 3.9.6 3.9.7 3.9.8 1.1.7 1.1.8 1.1.9 2.0.2 2.0.3 2.0.4 2.0.5 2.0.6 All 341 releases
profile-builder / admin / advanced-settings / includes / views / view-forms.php

view-forms.php in User Profile Builder – Beautiful User Registration Forms, User Profiles & User Role Editor 3.9.8, at admin/advanced-settings/includes/views/view-forms.php

410 lines 21.8 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php if ( ! defined( 'ABSPATH' ) ) exit; ?>
2
3 <?php
4 $settings = get_option( 'wppb_toolbox_forms_settings' );
5 ?>
6
7 <form method="post" action="options.php">
8
9 <?php settings_fields( 'wppb_toolbox_forms_settings' ); ?>
10
11 <table class="form-table">
12
13 <tr>
14 <th><?php esc_html_e( 'Enable Placeholder Labels', 'profile-builder' ); ?></th>
15
16 <td>
17 <input type="hidden" name="wppb_toolbox_forms_settings[placeholder-labels]" value="">
18 <label><input type="checkbox" name="wppb_toolbox_forms_settings[placeholder-labels]"<?php echo ( ( isset( $settings['placeholder-labels'] ) && ( $settings['placeholder-labels'] == 'yes' ) ) ? ' checked' : '' ); ?> value="yes">
19 <?php esc_html_e( 'Yes', 'profile-builder' ); ?>
20 </label>
21
22 <ul>
23 <li class="description">
24 <?php esc_html_e( 'Replace Labels with Placeholders in Profile Builder forms.', 'profile-builder' ); ?></li>
25 </ul>
26 </td>
27 </tr>
28
29 <tr>
30 <th><?php esc_html_e( 'Allow or deny email domains from registering', 'profile-builder' ); ?></th>
31
32 <td>
33 <ul class="wppb-toolbox-list">
34 <li>
35 <label>
36 <input type="checkbox" name="wppb_toolbox_forms_settings[restricted-email-domains]"<?php echo ( ( isset( $settings['restricted-email-domains'] ) && ( $settings['restricted-email-domains'] == 'on' ) ) ? ' checked' : '' ); ?> value="on" class="wppb-toolbox-switch">
37 <?php esc_html_e( 'On', 'profile-builder' ); ?>
38 </label>
39 </li>
40 </ul>
41
42 <div class="wppb-toolbox-accordion">
43 <ul class="wppb-toolbox-list">
44 <li class="toolbox-label">
45 <strong><?php esc_html_e( 'Type:', 'profile-builder' ); ?></strong>
46 </li>
47 <li>
48 <label>
49 <input type="radio" name="wppb_toolbox_forms_settings[restricted-email-domains-type]"<?php echo ( ( isset( $settings['restricted-email-domains-type'] ) && ( $settings['restricted-email-domains-type'] == 'allow' ) ) ? ' checked' : '' ); ?> value="allow">
50 <?php esc_html_e( 'Allow', 'profile-builder' ); ?>
51 </label>
52 </li>
53 <li>
54 <label>
55 <input type="radio" name="wppb_toolbox_forms_settings[restricted-email-domains-type]"<?php echo ( ( isset( $settings['restricted-email-domains-type'] ) && ( $settings['restricted-email-domains-type'] == 'deny' ) ) ? ' checked' : '' ); ?> value="deny">
56 <?php esc_html_e( 'Deny', 'profile-builder' ); ?>
57 </label>
58 </li>
59 </ul>
60
61 <ul class="wppb-toolbox-list">
62 <li class="toolbox-label">
63 <strong><?php esc_html_e( 'Restricted domains:', 'profile-builder' ); ?></strong>
64 </li>
65 <li class="toolbox-select2-container">
66 <select id="toolbox-restricted-emails" class="wppb-select" name="wppb_toolbox_forms_settings[restricted-email-domains-data][]" multiple="multiple">
67
68 <?php
69 if ( !empty( $settings['restricted-email-domains-data'] ) ) {
70 foreach( $settings['restricted-email-domains-data'] as $domain ) {
71 echo '<option value="'.esc_attr( $domain ).'" selected>'.esc_html( $domain ).'</option>';
72 }
73 }
74 ?>
75
76 </select>
77 </li>
78 </ul>
79
80 <ul class="wppb-toolbox-list">
81 <li class="toolbox-label">
82 <strong><?php esc_html_e( 'Error message:', 'profile-builder' ); ?></strong>
83 </li>
84 <li id="toolbox-restricted-email-domains-message">
85 <input type="text" name="wppb_toolbox_forms_settings[restricted-email-domains-message]" value="<?php echo ( !empty( $settings['restricted-email-domains-message']) ? esc_attr( $settings['restricted-email-domains-message'] ) : '' ); ?>">
86 </li>
87 </ul>
88
89 </div>
90
91 <ul>
92 <li class="description">
93 <?php esc_html_e( 'This option lets you allow registrations only from certain domains or deny registrations from certain domains.', 'profile-builder' ); ?>
94 </li>
95 <li class="description">
96 <?php esc_html_e( 'You should add only the domain in the list from above. eg.: gmail.com', 'profile-builder' ); ?>
97 </li>
98 </ul>
99 </td>
100 </tr>
101
102 <?php
103 $wppb_module_settings = get_option( 'wppb_module_settings' );
104
105 if ( $wppb_module_settings != false && isset( $wppb_module_settings['wppb_multipleRegistrationForms']) && $wppb_module_settings['wppb_multipleRegistrationForms'] == 'show' ) :
106 ?>
107 <tr>
108 <th scope="row"><?php esc_html_e( 'Forms that should bypass Email Confirmation', 'profile-builder' ); ?></th>
109
110 <td>
111 <label>
112 <select id="toolbox-bypass-ec" class="wppb-select" name="wppb_toolbox_forms_settings[ec-bypass][]" multiple="multiple">
113
114 <?php
115 $registration_forms = get_posts( array( 'post_type' => 'wppb-rf-cpt' ) );
116
117 if ( !empty( $registration_forms ) ) {
118 foreach ( $registration_forms as $form ) {
119 $form_slug = trim( Wordpress_Creation_Kit_PB::wck_generate_slug( $form->post_title ) );
120
121 ?>
122 <option value="<?php echo esc_attr( $form_slug ); ?>" <?php echo ( ( isset( $settings['ec-bypass'] ) && in_array( $form_slug, $settings['ec-bypass'] ) ) ? 'selected' : '' ); ?>>
123 <?php echo esc_html( $form->post_title ); ?>
124 </option>
125 <?php
126 }
127 }
128 ?>
129
130 </select>
131 </label>
132
133 <ul>
134 <li class="description">
135 <?php esc_html_e( 'Users registering through any of the selected forms will not need to confirm their email address.', 'profile-builder' ); ?>
136 </li>
137 </ul>
138 </td>
139 </tr>
140 <?php endif; ?>
141
142
143 <tr>
144 <th><?php esc_html_e( '“Email confirmation” when changing user email address', 'profile-builder' ); ?></th>
145
146 <td>
147 <label><input type="checkbox" name="wppb_toolbox_forms_settings[confirm-user-email-change]"<?php echo ( ( isset( $settings['confirm-user-email-change'] ) && ( $settings['confirm-user-email-change'] == 'yes' ) ) ? ' checked' : '' ); ?> value="yes">
148 <?php esc_html_e( 'Yes', 'profile-builder' ); ?>
149 </label>
150
151 <ul>
152 <li class="description">
153 <?php esc_html_e( 'If checked, an activation email is sent for the new email address.', 'profile-builder' ); ?>
154 </li>
155 </ul>
156 </td>
157 </tr>
158
159 <?php if ( defined( 'WPPB_PAID_PLUGIN_DIR' ) && file_exists( WPPB_PAID_PLUGIN_DIR.'/add-ons-advanced/social-connect/index.php' ) ) : ?>
160
161 <tr>
162 <th><?php esc_html_e( 'Disable Email Confirmation for Social Connect registrations', 'profile-builder' ); ?></th>
163
164 <td>
165 <label><input type="checkbox" name="wppb_toolbox_forms_settings[social-connect-bypass-ec]"<?php echo ( ( isset( $settings['social-connect-bypass-ec'] ) && ( $settings['social-connect-bypass-ec'] == 'yes' ) ) ? ' checked' : '' ); ?> value="yes">
166 <?php esc_html_e( 'Yes', 'profile-builder' ); ?>
167 </label>
168
169 <ul>
170 <li class="description">
171 <?php esc_html_e( 'If checked, will allow users that register through the Social Connect add-on to bypass the Email Confirmation feature.', 'profile-builder' ); ?>
172 </li>
173 </ul>
174 </td>
175 </tr>
176 <?php endif; ?>
177
178 <tr>
179 <th><?php esc_html_e( 'Remember me checked by default', 'profile-builder' ); ?></th>
180
181 <td>
182 <label><input type="checkbox" name="wppb_toolbox_forms_settings[remember-me]"<?php echo ( ( isset( $settings['remember-me'] ) && ( $settings['remember-me'] == 'yes' ) ) ? ' checked' : '' ); ?> value="yes">
183 <?php esc_html_e( 'Yes', 'profile-builder' ); ?>
184 </label>
185
186 <ul>
187 <li class="description">
188 <?php esc_html_e( 'Check the \'Remember Me\' checkbox on Login forms, by default.', 'profile-builder' ); ?></li>
189 </ul>
190 </td>
191 </tr>
192
193 <tr>
194 <th><?php esc_html_e( 'Automatically log in users after password reset', 'profile-builder' ); ?></th>
195
196 <td>
197 <label><input type="checkbox" name="wppb_toolbox_forms_settings[recover-password-autologin]"<?php echo ( ( isset( $settings['recover-password-autologin'] ) && ( $settings['recover-password-autologin'] == 'yes' ) ) ? ' checked' : '' ); ?> value="yes">
198 <?php esc_html_e( 'Yes', 'profile-builder' ); ?>
199 </label>
200
201 <ul>
202 <li class="description">
203 <?php esc_html_e( 'Automatically log in users after they reset their password using the Recover Password form.', 'profile-builder' ); ?></li>
204 </ul>
205 </td>
206 </tr>
207
208 <tr>
209 <th><?php esc_html_e( 'Remove validation from back-end profile page', 'profile-builder' ); ?></th>
210
211 <td>
212 <label><input type="checkbox" name="wppb_toolbox_forms_settings[back-end-validation]"<?php echo ( ( isset( $settings['back-end-validation'] ) && ( $settings['back-end-validation'] == 'yes' ) ) ? ' checked' : '' ); ?> value="yes">
213 <?php esc_html_e( 'Yes', 'profile-builder' ); ?>
214 </label>
215
216 <ul>
217 <li class="description">
218 <?php esc_html_e( 'When saving the back-end user profile, Profile Builder fields will not be validated anymore. eg.: bypass required attribute', 'profile-builder' ); ?>
219 </li>
220 </ul>
221 </td>
222 </tr>
223
224 <?php
225 $users = count_users();
226
227 if ( $users['total_users'] >= 5000 ) : ?>
228 <tr>
229 <th><?php esc_html_e( 'Always show edit other users dropdown', 'profile-builder' ); ?></th>
230
231 <td>
232 <label><input type="checkbox" name="wppb_toolbox_forms_settings[edit-other-users-limit]"<?php echo ( ( isset( $settings['edit-other-users-limit'] ) && ( $settings['edit-other-users-limit'] == 'yes' ) ) ? ' checked' : '' ); ?> value="yes">
233 <?php esc_html_e( 'Yes', 'profile-builder' ); ?>
234 </label>
235
236 <ul>
237 <li class="description">
238 <?php esc_html_e( 'For perfomance reasons, we disable the select if you have more than 5000 users on your website. This option lets you enable it again.', 'profile-builder' ); ?>
239 </li>
240 </ul>
241 </td>
242 </tr>
243 <?php endif; ?>
244
245 <tr>
246 <th><?php esc_html_e( 'Consider \'Anyone can Register\' WordPress option', 'profile-builder' ); ?></th>
247
248 <td>
249 <label><input type="checkbox" name="wppb_toolbox_forms_settings[users-can-register]"<?php echo ( ( isset( $settings['users-can-register'] ) && ( $settings['users-can-register'] == 'yes' ) ) ? ' checked' : '' ); ?> value="yes">
250 <?php esc_html_e( 'Yes', 'profile-builder' ); ?>
251 </label>
252
253 <ul>
254 <li class="description">
255 <?php
256 echo wp_kses_post( sprintf( __( 'By default, Profile Builder ignores this %1$s. If you check this option, our registration form will consider it.', 'profile-builder' ), '<a href="'. esc_url( admin_url( 'options-general.php' ) ) .'" target="_blank">' . esc_html__( 'setting', 'profile-builder' ) . '</a>' ) );
257 ?>
258 </li>
259 </ul>
260 </td>
261 </tr>
262
263 <tr>
264 <th><?php esc_html_e( 'Modify default Redirect Delay timer', 'profile-builder' ); ?></th>
265
266 <td>
267 <input type="text" name="wppb_toolbox_forms_settings[redirect-delay-timer]" value="<?php echo ( ( !empty( $settings['redirect-delay-timer'] ) || ( isset( $settings['redirect-delay-timer'] ) && $settings['redirect-delay-timer'] == 0 ) ) ? esc_attr( $settings['redirect-delay-timer'] ) : '' ); ?>">
268
269 <ul>
270 <li class="description">
271 <?php echo wp_kses_post( __( 'This allows you to change the amount of seconds it takes for the <strong>\'After Registration\'</strong> redirect to happen.', 'profile-builder' ) ); ?>
272 </li>
273 <li class="description">
274 <?php esc_html_e( 'The default is 3 seconds. Leave empty if you do not want to change it.', 'profile-builder' ); ?>
275 </li>
276 </ul>
277 </td>
278 </tr>
279
280 <?php if ( defined( 'WPPB_PAID_PLUGIN_DIR' ) && file_exists( WPPB_PAID_PLUGIN_DIR.'/features/admin-approval/admin-approval.php' ) ) : ?>
281 <tr>
282 <th><?php esc_html_e( 'Save Admin Approval status in usermeta', 'profile-builder' ); ?></th>
283
284 <td>
285 <label><input type="checkbox" name="wppb_toolbox_forms_settings[save-admin-approval-status]"<?php echo ( ( isset( $settings['save-admin-approval-status'] ) && ( $settings['save-admin-approval-status'] == 'yes' ) ) ? ' checked' : '' ); ?> value="yes">
286 <?php esc_html_e( 'Yes', 'profile-builder' ); ?>
287 </label>
288
289 <ul>
290 <li class="description">
291 <?php esc_html_e( 'By default, the Admin Approval status is saved as a custom taxonomy that is attached to the user.', 'profile-builder' ); ?>
292 </li>
293 <li class="description">
294 <?php echo wp_kses_post( __( 'If you check this option, the status will also be saved in the \'*_usermeta\' table under the <strong>wppb_approval_status</strong> meta name.', 'profile-builder' ) ); ?>
295 </li>
296 </ul>
297 </td>
298 </tr>
299 <?php endif; ?>
300
301 <?php if ( defined( 'WPPB_PAID_PLUGIN_DIR' ) && file_exists( WPPB_PAID_PLUGIN_DIR.'/features/admin-approval/admin-approval.php' ) ) : ?>
302 <tr>
303 <th><?php esc_html_e( 'Redirect \'/author\' page if user is not approved', 'profile-builder' ); ?></th>
304
305 <td>
306 <label><input type="checkbox" name="wppb_toolbox_forms_settings[redirect-author-page]"<?php echo ( ( isset( $settings['redirect-author-page'] ) && ( $settings['redirect-author-page'] == 'yes' ) ) ? ' checked' : '' ); ?> value="yes">
307 <?php esc_html_e( 'Yes', 'profile-builder' ); ?>
308 </label>
309
310 <ul>
311 <li class="description">
312 <?php esc_html_e( 'By default, users placed in Admin Approval will not be able to login, but the Author pages will be accessible.', 'profile-builder' ); ?>
313 </li>
314 <li class="description">
315 <?php esc_html_e( 'Using this option you can redirect these pages, sending users who try to access them to your home page.', 'profile-builder' ); ?>
316 </li>
317 </ul>
318 </td>
319 </tr>
320 <?php endif; ?>
321
322 <tr>
323 <th><?php esc_html_e( 'Save \'Last Login\' date in usermeta', 'profile-builder' ); ?></th>
324
325 <td>
326 <label><input type="checkbox" name="wppb_toolbox_forms_settings[save-last-login]"<?php echo ( ( isset( $settings['save-last-login'] ) && ( $settings['save-last-login'] == 'yes' ) ) ? ' checked' : '' ); ?> value="yes">
327 <?php esc_html_e( 'Yes', 'profile-builder' ); ?>
328 </label>
329
330 <ul>
331 <li class="description">
332 <?php esc_html_e( 'By checking this option, each time a user logins, the date and time will be saved in the database.', 'profile-builder' ); ?>
333 </li>
334 <li class="description">
335 <?php echo wp_kses_post( __( 'The meta name for the field will be <strong>last_login_date</strong>.', 'profile-builder' ) ); ?>
336 </li>
337 <li class="description">
338 <?php echo wp_kses_post( __( 'You can <a href="https://www.cozmoslabs.com/docs/profile-builder-2/manage-user-fields/#Manage_existing_custom_fields_with_Profile_Builder" target="_blank">create a field with this meta name</a> in Profile Builder to display it in the Userlisting or Edit Profile forms.', 'profile-builder' ) ); ?>
339 </li>
340 </ul>
341 </td>
342 </tr>
343
344 <tr>
345 <th><?php esc_html_e( 'Save \'Last Profile Update\' date in usermeta', 'profile-builder' ); ?></th>
346
347 <td>
348 <label><input type="checkbox" name="wppb_toolbox_forms_settings[save-last-profile-update]"<?php echo ( ( isset( $settings['save-last-profile-update'] ) && ( $settings['save-last-profile-update'] == 'yes' ) ) ? ' checked' : '' ); ?> value="yes">
349 <?php esc_html_e( 'Yes', 'profile-builder' ); ?>
350 </label>
351
352 <ul>
353 <li class="description">
354 <?php esc_html_e( 'By checking this option, each time a modifies his profile the date and time will be saved in the database.', 'profile-builder' ); ?>
355 </li>
356 <li class="description">
357 <?php echo wp_kses_post( __( 'The meta name for the field will be <strong>last_profile_update_date</strong>.', 'profile-builder' ) ); ?>
358 </li>
359 <li class="description">
360 <?php echo wp_kses_post( __( 'You can <a href="https://www.cozmoslabs.com/docs/profile-builder-2/manage-user-fields/#Manage_existing_custom_fields_with_Profile_Builder" target="_blank">create a field with this meta name</a> in Profile Builder to display it in the Userlisting or Edit Profile forms.', 'profile-builder' ) ); ?>
361 </li>
362 </ul>
363 </td>
364 </tr>
365
366 <tr>
367 <th><?php esc_html_e( 'Disable automatic scrolling after submit', 'profile-builder' ); ?></th>
368
369 <td>
370 <label><input type="checkbox" name="wppb_toolbox_forms_settings[disable-automatic-scrolling]"<?php echo ( ( isset( $settings['disable-automatic-scrolling'] ) && ( $settings['disable-automatic-scrolling'] == 'yes' ) ) ? ' checked' : '' );?> value="yes">
371 <?php esc_html_e( 'Yes', 'profile-builder' ); ?>
372 </label>
373
374 <ul>
375 <li class="description">
376 <?php esc_html_e( 'By default, after each form submission the page will automatically scroll to the form message.', 'profile-builder' ); ?>
377 </li>
378 <li class="description">
379 <?php esc_html_e( 'If you check this option, automatic scrolling will be disabled.', 'profile-builder' ); ?>
380 </li>
381 </ul>
382 </td>
383 </tr>
384
385 <?php if( wppb_conditional_fields_exists() ): ?>
386 <tr>
387 <th scope="row"><?php esc_html_e( 'Use ajax on conditional fields:', 'profile-builder' );?></th>
388
389 <td>
390 <label><input type="checkbox" name="wppb_toolbox_forms_settings[ajax-conditional-logic]"<?php echo ( ( isset( $settings['ajax-conditional-logic'] ) && ( $settings['ajax-conditional-logic'] == 'yes' ) ) ? ' checked' : '' );?> value="yes">
391 <?php esc_html_e( 'Yes', 'profile-builder' ); ?>
392 </label>
393 <ul>
394 <li class="description">
395 <?php esc_html_e( 'For large conditional forms.', 'profile-builder' ); ?>
396 </li>
397 <li class="description">
398 <?php esc_html_e( 'Select "Yes" for improved page performance.', 'profile-builder' ); ?>
399 </li>
400 </ul>
401 </td>
402 </tr>
403 <?php endif; ?>
404
405 </table>
406
407 <?php submit_button( __( 'Save Changes', 'profile-builder' ) ); ?>
408
409 </form>
410