save_settings(); } elseif ( isset( $_POST['tadv-restore-defaults'] ) ) { check_admin_referer( 'tadv-save-buttons-order' ); // TODO: only for admin || SA $this->admin_settings = $this->get_default_admin_settings(); update_option( 'tadv_admin_settings', $this->get_default_admin_settings() ); // TODO: all users that can have settings $this->user_settings = $this->get_default_user_settings(); update_option( 'tadv_settings', $this->get_default_user_settings() ); $message = '

' . __( 'Default settings restored.', 'tinymce-advanced' ) . '

'; } elseif ( isset( $_POST['tadv-import-settings'] ) ) { check_admin_referer( 'tadv-save-buttons-order' ); // TODO: all users ?>


' . __( 'Importing of settings failed.', 'tinymce-advanced' ) . '

'; } else { $this->save_settings( $import ); $message = '

' . __( 'Settings imported successfully.', 'tinymce-advanced' ) . '

'; } } elseif ( isset( $_GET['tadv-import-file-complete'] ) ) { $err = (int) $_GET['tadv-import-file-complete']; switch( $err ) { case 1: $message = __( 'Importing of settings failed. Please import a valid settings file.', 'tinymce-advanced' ); break; case 2: $message = __( 'Importing of settings failed. The imported file is empty.', 'tinymce-advanced' ); break; case 3: $message = __( 'Importing of settings failed. The imported file is invalid.', 'tinymce-advanced' ); break; } if ( empty( $message ) ) { $message = '

' . __( 'Settings imported successfully.', 'tinymce-advanced' ) . '

'; } else { $message = '

' . $message . '

'; } } $this->load_settings(); if ( empty( $this->toolbar_1 ) && empty( $this->toolbar_2 ) && empty( $this->toolbar_3 ) && empty( $this->toolbar_4 ) ) { $message = '

' . __( 'ERROR: All toolbars are empty. Default settings loaded.', 'tinymce-advanced' ) . '

'; $this->admin_settings = $this->get_default_admin_settings(); $this->user_settings = $this->get_default_user_settings(); $this->load_settings(); } $all_buttons = $this->get_all_buttons(); ?>

warn_if_unsupported(); if ( isset( $_POST['tadv-save'] ) && empty( $message ) ) { ?>

Mark button will wrap the selected text in a plain <mark> HTML element. The appearance would depend on your theme and usually resembles highlighted text.', 'tinymce-advanced' ); ?>

Clear formatting button will remove text formatting from the selected text, or from the whole paragraph if there is no selection. This includes femoval of most text styling like bold, italic, underline, background and foreground color, etc.', 'tinymce-advanced' ); ?>

check_user_setting( 'disable_richtext_buttons' ) ) echo ' checked'; ?>>
check_user_setting( 'disable_richtext_buttons' ) ) echo ' checked'; ?>>

check_user_setting( 'menubar_block' ) ) { echo ' checked'; } ?>>

    toolbar_classic_block as $button_id ) { $name = ''; if ( strpos( $button_id, 'separator' ) !== false || in_array( $button_id, array( 'moveforward', 'movebackward', 'absolute' ) ) ) { continue; } if ( isset( $all_buttons_block[ $button_id ] ) ) { $name = $all_buttons_block[ $button_id ]; unset( $all_buttons_block[ $button_id ] ); } else { continue; } ?>

    $name ) { if ( strpos( $button_id, 'separator' ) !== false ) { continue; } ?>

check_user_setting( 'menubar' ) ) { echo ' checked="checked"'; } ?>>

    $toolbar as $button_id ) { if ( strpos( $button_id, 'separator' ) !== false || in_array( $button_id, array( 'moveforward', 'movebackward', 'absolute' ) ) ) { continue; } if ( isset( $all_buttons_classic[ $button_id ] ) ) { $name = $all_buttons_classic[ $button_id ]; unset( $all_buttons_classic[ $button_id ] ); } else { continue; } ?>

    $name ) { if ( strpos( $button_id, 'separator' ) !== false ) { continue; } ?>

check_user_setting( 'merge_toolbars' ) ) echo ' checked'; ?> />

check_user_setting('advlist') ) echo ' checked'; ?> />

check_user_setting('contextmenu') ) echo ' checked'; ?> />

check_user_setting('advlink') ) echo ' checked'; ?> />

check_user_setting( 'fontsize_formats' ) ) echo ' checked="checked"'; ?> />

fontsize_formats ); ?>

check_admin_setting( 'classic_paragraph_block' ) ) echo ' checked'; ?> />

check_admin_setting( 'hybrid_mode' ) ) echo ' checked'; ?> />

check_admin_setting( 'replace_block_editor' ) ) echo ' checked'; ?> />

', '' ); ?>

check_admin_setting( 'no_autop' ) ) echo ' checked'; ?> />

has_editor_style(); $disabled = ' disabled'; if ( $has_editor_style === false ) { add_editor_style(); $has_editor_style = $this->has_editor_style(); } if ( $has_editor_style ) { $disabled = ''; } ?>
check_admin_setting( 'importcss' ) ) echo ' checked'; echo $disabled; ?> />


check_admin_setting( 'table_resize_bars' ) ) echo ' checked'; ?> />

check_admin_setting( 'table_default_attributes' ) ) echo ' checked'; ?> />

check_admin_setting( 'table_grid' ) ) echo ' checked'; ?> />

check_admin_setting( 'table_tab_navigation' ) ) echo ' checked'; ?> />

check_admin_setting( 'table_advtab' ) ) echo ' checked'; ?> />

 

check_admin_setting( 'enable_edit_post_screen' ) ) echo ' checked'; ?> />

check_admin_setting( 'enable_rest_of_wpadmin' ) ) echo ' checked'; ?> />

check_admin_setting( 'enable_on_front_end' ) ) echo ' checked'; ?> />