PluginProbe
User Profile Builder – Beautiful User Registration Forms, User Profiles & User Role Editor / 4.0.3
User Profile Builder – Beautiful User Registration Forms, User Profiles & User Role Editor v4.0.3
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
← All changes | admin/general-settings.php +10 -35 3.16.04.0.3 View file →
@@ -166,8 +166,9 @@
166 166 <?php settings_fields( 'wppb_general_settings' ); ?>
167 167
168 168 <div class="cozmoslabs-settings">
169 169
170 + <?php if ( defined( 'WPPB_PAID_PLUGIN_DIR' ) && file_exists( WPPB_PAID_PLUGIN_DIR . '/features/form-designs/form-designs.php' ) ) : ?>
170 171 <div class="cozmoslabs-form-subsection-wrapper" id="wppb-form_desings">
171 172 <h4 class="cozmoslabs-subsection-title"><?php esc_html_e( 'Design & User Experience', 'profile-builder' ); ?></h4>
172 173 <p class="cozmoslabs-description" style="margin-bottom: 5px;"><?php esc_html_e( 'Choose a style that better suits your website.', 'profile-builder' ); ?></p>
173 174 <p class="cozmoslabs-description"><?php esc_html_e( 'The default style is there to let you customize the CSS and in general will receive the look and feel from your own theme’s styling.', 'profile-builder' ); ?></p>
@@ -172,18 +173,12 @@
172 173 <p class="cozmoslabs-description" style="margin-bottom: 5px;"><?php esc_html_e( 'Choose a style that better suits your website.', 'profile-builder' ); ?></p>
173 174 <p class="cozmoslabs-description"><?php esc_html_e( 'The default style is there to let you customize the CSS and in general will receive the look and feel from your own theme’s styling.', 'profile-builder' ); ?></p>
174 175
175 176 <div class="cozmoslabs-form-field-wrapper">
176 - <?php
177 - if ( defined( 'WPPB_PAID_PLUGIN_DIR' ) && file_exists( WPPB_PAID_PLUGIN_DIR.'/features/form-designs/form-designs.php' ) ) {
178 - echo wppb_render_forms_design_selector(); //phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
179 - }
180 - elseif ( PROFILE_BUILDER == 'Profile Builder Free' ) {
181 - echo wppb_display_form_designs_preview(); //phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
182 - }
183 - ?>
177 + <?php echo wppb_render_forms_design_selector(); //phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
184 178 </div>
185 179 </div>
180 + <?php endif; ?>
186 181
187 182 <div class="cozmoslabs-form-subsection-wrapper">
188 183 <h4 class="cozmoslabs-subsection-title"><?php esc_html_e( 'Optimize The login and Registration flow for your members', 'profile-builder' ); ?></h4>
189 184
@@ -363,13 +358,12 @@
363 358 <p class="cozmoslabs-description cozmoslabs-description-space-left"><?php esc_html_e( 'Select the page which contains the "[wppb-recover-password]" shortcode.', 'profile-builder' ); ?></p>
364 359 </div>
365 360 </div>
366 361
362 + <?php if ( defined( 'WPPB_PAID_PLUGIN_DIR' ) && file_exists( WPPB_PAID_PLUGIN_DIR . '/features/two-factor-authentication/class-two-factor-authentication.php' ) ) : ?>
367 363 <div class="cozmoslabs-form-subsection-wrapper">
368 364 <h4 class="cozmoslabs-subsection-title"><?php esc_html_e( 'Two-Factor Authentication', 'profile-builder' ); ?></h4>
369 365
370 - <?php if( defined( 'WPPB_PAID_PLUGIN_DIR' ) && file_exists( WPPB_PAID_PLUGIN_DIR . '/features/two-factor-authentication/class-two-factor-authentication.php' ) ) : ?>
371 -
372 366 <div class="cozmoslabs-form-field-wrapper cozmoslabs-toggle-switch">
373 367 <?php
374 368 $wppb_two_factor_authentication_settings = get_option( 'wppb_two_factor_authentication_settings', 'not_found' );
375 369
@@ -730,13 +724,15 @@
730 724 $edit_profile_page_id = $wppb_two_factor_authentication_settings['edit_profile_page_id'];
731 725 }
732 726
733 727 // Get pages with Edit Profile shortcode or block
728 + $edit_profile_pages = array();
734 729 if ( defined( 'WPPB_PAID_PLUGIN_DIR' ) && file_exists( WPPB_PAID_PLUGIN_DIR . '/features/two-factor-authentication/class-two-factor-authentication.php' ) ) {
735 730 require_once( WPPB_PAID_PLUGIN_DIR . '/features/two-factor-authentication/class-two-factor-authentication.php' );
736 - $edit_profile_pages = WPPB_Two_Factor_Authenticator::get_edit_profile_pages();
737 - } else {
738 - $edit_profile_pages = array();
731 + // The method only exists in paid add-on versions matching this base plugin; guard against a stale add-on to avoid a fatal error.
732 + if ( method_exists( 'WPPB_Two_Factor_Authenticator', 'get_edit_profile_pages' ) ) {
733 + $edit_profile_pages = WPPB_Two_Factor_Authenticator::get_edit_profile_pages();
734 + }
739 735 }
740 736 ?>
741 737
742 738 <label class="cozmoslabs-form-field-label" for="wppb-force-2fa-edit-profile-page"><?php esc_html_e( 'Redirect to Edit Profile Page', 'profile-builder' ); ?></label>
@@ -764,31 +760,10 @@
764 760 </div>
765 761
766 762
767 763
768 - <?php else : ?>
769 -
770 - <div class="cozmoslabs-form-field-wrapper cozmoslabs-toggle-switch">
771 -
772 - <label class="cozmoslabs-form-field-label" for="wppb-2fa-enable"><?php esc_html_e('Two-Factor Authentication', 'profile-builder'); ?></label>
773 -
774 - <div class="cozmoslabs-toggle-container">
775 - <input type="checkbox" name="wppb_two_factor_authentication_free" id="wppb-2fa-enable" value="yes">
776 - <label class="cozmoslabs-toggle-track" for="wppb-2fa-enable"></label>
777 - </div>
778 -
779 - <div class="cozmoslabs-toggle-description">
780 - <label for="wppb-2fa-enable" class="cozmoslabs-description"><?php esc_html_e( 'Enable the Google Authenticator functionality.', 'profile-builder' ); ?></label>
781 - </div>
782 -
783 - <p class="cozmoslabs-description cozmoslabs-description-upsell" id="wppb-2fa-upgrade-notice" style="display: none;">
784 - <?php printf( esc_html__( 'Increase the security of your user accounts with 2 Factor Authentication by upgrading to %1$sBasic or Pro%2$s versions.', 'profile-builder' ), '<a href="https://www.cozmoslabs.com/wordpress-profile-builder/?utm_source=wpbackend&utm_medium=clientsite&utm_content=settings-2fa&utm_campaign=PBFree#pricing" target="_blank">', '</a>' );?>
785 - </p>
786 -
787 - </div>
788 -
789 - <?php endif; ?>
790 764 </div>
765 + <?php endif; ?>
791 766
792 767 <div class="cozmoslabs-form-subsection-wrapper">
793 768 <h4 class="cozmoslabs-subsection-title"><?php esc_html_e( 'Other features', 'profile-builder' ); ?></h4>
794 769