| 1 |
<?php |
| 2 |
|
| 3 |
|
| 4 |
// Misc Settings |
| 5 |
|
| 6 |
add_action( 'ucd_settings_content', 'ucd_misc_page' ); |
| 7 |
function ucd_misc_page() { |
| 8 |
global $ucd_active_tab; |
| 9 |
if ( 'misc' != $ucd_active_tab ) |
| 10 |
return; |
| 11 |
?> |
| 12 |
|
| 13 |
<h3><?php _e( 'Misc Settings', 'ultimate-client-dash' ); ?></h3> |
| 14 |
|
| 15 |
<!-- Begin settings form --> |
| 16 |
<form action="options.php" method="post"> |
| 17 |
<?php |
| 18 |
settings_fields( 'ultimate-client-dash-misc' ); |
| 19 |
do_settings_sections( 'ultimate-client-dash-misc' ); |
| 20 |
?> |
| 21 |
|
| 22 |
<!-- Misc Option Section --> |
| 23 |
|
| 24 |
<div class="ucd-inner-wrapper settings-misc"> |
| 25 |
<p class="ucd-settings-desc">Rebrand your WordPress theme and disable WordPress notifications and nags, PHP errors, and auto update emails.</p> |
| 26 |
|
| 27 |
<div class="ucd-form-message"><?php settings_errors('ucd-notices'); ?></div> |
| 28 |
|
| 29 |
<table class="form-table"> |
| 30 |
<tbody> |
| 31 |
|
| 32 |
<tr class="ucd-title-holder"> |
| 33 |
<th><h2 class="ucd-inner-title"><?php _e( 'Rebrand Theme', 'ultimate-client-dash' ) ?></h2></th> |
| 34 |
</tr> |
| 35 |
|
| 36 |
<tr class="ucd-pro-version"> |
| 37 |
<th><?php _e( 'Theme Name', 'ultimate-client-dash' ) ?> |
| 38 |
<p> |
| 39 |
Replace any use of the theme name in the WordPress dashboard. |
| 40 |
</p></th> |
| 41 |
<td><input class="regular-text" type="text" placeholder="WP Codeus" name="ucd_pro_misc_theme_name" value="<?php echo esc_attr( get_option('ucd_pro_misc_theme_name') ); ?>" size="70" /> |
| 42 |
<p> |
| 43 |
Enter theme name you wish to replace. Works with most themes... |
| 44 |
</p> |
| 45 |
</td> |
| 46 |
</tr> |
| 47 |
|
| 48 |
<tr class="ucd-pro-version"> |
| 49 |
<th><?php _e( 'Rebrand Name', 'ultimate-client-dash' ) ?> |
| 50 |
<p> |
| 51 |
Name which will replace the theme name. |
| 52 |
</p></th> |
| 53 |
<td> |
| 54 |
<input class="regular-text" type="text" placeholder="WPC" name="ucd_pro_misc_custom_name" value="<?php echo esc_attr( get_option('ucd_pro_misc_custom_name') ); ?>" size="70" /> |
| 55 |
<p> |
| 56 |
Enter the rebrand name you wish to use. Works with most themes... |
| 57 |
</p> |
| 58 |
</td> |
| 59 |
</tr> |
| 60 |
|
| 61 |
<tr class="ucd-title-holder"> |
| 62 |
<th><h2 class="ucd-inner-title"><?php _e( 'Notifications', 'ultimate-client-dash' ) ?></h2></th> |
| 63 |
</tr> |
| 64 |
|
| 65 |
<tr class="ucd-pro-version"> |
| 66 |
<th><?php _e( 'Disable Client Nags & Notices', 'ultimate-client-dash' ) ?></th> |
| 67 |
<td><label class="ucd-switch"><input type="checkbox" name="ucd_pro_misc_client_nags" value="ucd_pro_misc_client_nags" <?php checked( 'ucd_pro_misc_client_nags', get_option( 'ucd_pro_misc_client_nags' ) ); ?> /><span class="ucd-slider round"></span></label>Enable |
| 68 |
<p>Toggle to disable all WordPress Core update notifications and nags in the WordPress dashboard for user role 'Client'.</p> |
| 69 |
</td> |
| 70 |
</tr> |
| 71 |
|
| 72 |
<tr class="ucd-pro-version"> |
| 73 |
<th><?php _e( 'Disable Fatal Error Protection', 'ultimate-client-dash' ) ?></th> |
| 74 |
<td><label class="ucd-switch"><input type="checkbox" name="ucd_pro_misc_fatal_error" value="ucd_pro_misc_fatal_error" <?php checked( 'ucd_pro_misc_fatal_error', get_option( 'ucd_pro_misc_fatal_error' ) ); ?> /><span class="ucd-slider round"></span></label>Enable |
| 75 |
<p>Toggle to disable fatal PHP error protection email notifications. Added in WordPress 5.2.</p> |
| 76 |
</td> |
| 77 |
</tr> |
| 78 |
|
| 79 |
<tr class="ucd-pro-version"> |
| 80 |
<th><?php _e( 'Disable Auto Update Email', 'ultimate-client-dash' ) ?></th> |
| 81 |
<td><label class="ucd-switch"><input type="checkbox" name="ucd_pro_misc_update_email" value="ucd_pro_misc_update_email" <?php checked( 'ucd_pro_misc_update_email', get_option( 'ucd_pro_misc_update_email' ) ); ?> /><span class="ucd-slider round"></span></label>Enable |
| 82 |
<p>Toggle to disable WordPress auto update email notification.</p> |
| 83 |
</td> |
| 84 |
</tr> |
| 85 |
|
| 86 |
<tr class="ucd-title-holder"> |
| 87 |
<th><h2 class="ucd-inner-title"><?php _e( 'Extra Settings', 'ultimate-client-dash' ) ?></h2></th> |
| 88 |
</tr> |
| 89 |
|
| 90 |
<tr> |
| 91 |
<th><?php _e( 'Frontend Admin Bar Styling', 'ultimate-client-dash' ) ?></th> |
| 92 |
<td><label class="ucd-switch"><input type="checkbox" name="ucd_misc_admin_bar_frontend_styling" value="ucd_misc_admin_bar_frontend_styling" <?php checked( 'ucd_misc_admin_bar_frontend_styling', get_option( 'ucd_misc_admin_bar_frontend_styling' ) ); ?> /><span class="ucd-slider round"></span></label>Disable |
| 93 |
<p>Disable the frontend admin bar color styling.</p> |
| 94 |
</td> |
| 95 |
</tr> |
| 96 |
|
| 97 |
<tr class="ucd-pro-version"> |
| 98 |
<th><?php _e( 'Hide UCD Plugin', 'ultimate-client-dash' ) ?></th> |
| 99 |
<td><label class="ucd-switch"><input type="checkbox" name="ucd_pro_misc_hide_plugin" value="ucd_pro_misc_hide_plugin" <?php checked( 'ucd_pro_misc_hide_plugin', get_option( 'ucd_pro_misc_hide_plugin' ) ); ?> /><span class="ucd-slider round"></span></label>Enable |
| 100 |
<p>Toggle to hide Ultimate Client Dash from the plugin list for user role 'Client'.</p> |
| 101 |
</td> |
| 102 |
</tr> |
| 103 |
|
| 104 |
<tr class="ucd-title-holder"> |
| 105 |
<th><h2 class="ucd-inner-title"><?php _e( 'Customization', 'ultimate-client-dash' ) ?></h2></th> |
| 106 |
</tr> |
| 107 |
|
| 108 |
<tr> |
| 109 |
<td style="padding-left: 0px!important; padding-top: 10 px!important;"><p>Add your own customization options here. Click here to view our online <a href="https://ultimateclientdash.com/hooks/" target="_blank">documention</a>.</p></td> |
| 110 |
</tr> |
| 111 |
|
| 112 |
<!-- Action hook to allow developers to add their own settings to Ultimate Client Dash --> |
| 113 |
<?php do_action( 'ucd_hook_misc_customization' ); ?> |
| 114 |
|
| 115 |
<tr class="ucd-float-option"> |
| 116 |
<th class="ucd-save-section"> |
| 117 |
<?php submit_button(); ?> |
| 118 |
</th> |
| 119 |
</tr> |
| 120 |
|
| 121 |
</tbody> |
| 122 |
</table> |
| 123 |
</div> |
| 124 |
</form> |
| 125 |
<?php } |
| 126 |
|