|
16 | 16 | *
|
17 | 17 | * @package ReduxFramework
|
18 | 18 | * @author Daniel J Griffiths (Ghost1227)
|
19 |
| - * @author Dovy Paukstys |
20 |
| - * @version 3.0.0 |
| 19 | + * @author Dovy Paukstys (dovy) |
| 20 | + * @version 3.0.1 |
21 | 21 | */
|
22 | 22 |
|
23 | 23 | // Exit if accessed directly
|
|
26 | 26 | // Don't duplicate me!
|
27 | 27 | if( !class_exists( 'ReduxFramework' ) ) {
|
28 | 28 |
|
29 |
| -define('REDUX_VERSION', '3.0.0'); |
| 29 | +define('REDUX_VERSION', '3.0.1'); |
30 | 30 |
|
31 | 31 | // Windows-proof constants: replace backward by forward slashes
|
32 | 32 | // Thanks to: https://github.com/peterbouwmeester
|
@@ -116,9 +116,9 @@ public function __construct( $sections = array(), $args = array(), $extra_tabs =
|
116 | 116 | $defaults['dev_mode'] = false;
|
117 | 117 | $defaults['system_info'] = false;
|
118 | 118 | $defaults['admin_stylesheet'] = 'standard';
|
119 |
| - $defaults['footer_credit'] = __( '<span id="footer-thankyou">Options panel created using <a href="' . $this->framework_url . '" target="_blank">Redux Framework</a> v' . $this->framework_version . '</span>', 'redux-framework' ); |
| 119 | + $defaults['footer_credit'] = '<span id="footer-thankyou">' . __( 'Options panel created using', 'redux-framework') . '<a href="' . $this->framework_url . '" target="_blank">' . __('Redux Framework', 'redux-framework') . '</a> v' . $this->framework_version . '</span>'; |
120 | 120 | $defaults['help_tabs'] = array();
|
121 |
| - $defaults['help_sidebar'] = __( '', 'redux-framework' ); |
| 121 | + $defaults['help_sidebar'] = ''; // __( '', 'redux-framework' ); |
122 | 122 | $defaults['database'] = ''; // possible: options, theme_mods, theme_mods_expanded, transient
|
123 | 123 | $defaults['customizer'] = true; // setting to true forces get_theme_mod_expanded
|
124 | 124 | $defaults['global_variable'] = '';
|
@@ -618,6 +618,9 @@ function _options_page() {
|
618 | 618 | if ( !isset( $section['title'] ) )
|
619 | 619 | continue;
|
620 | 620 |
|
| 621 | + if ( isset( $section['submenu'] ) && $section['submenu'] == false ) |
| 622 | + continue; |
| 623 | + |
621 | 624 | add_submenu_page(
|
622 | 625 | $this->args['page_slug'],
|
623 | 626 | $section['title'],
|
@@ -1055,11 +1058,7 @@ public function _register_setting() {
|
1055 | 1058 | if( isset( $field['title'] ) && isset( $field['type'] ) && $field['type'] !== "info" ) {
|
1056 | 1059 | $default_mark = ( !empty($field['default']) && isset($this->options[$field['id']]) && $this->options[$field['id']] == $field['default'] && !empty( $this->args['default_mark'] ) && isset( $field['default'] ) ) ? $this->args['default_mark'] : '';
|
1057 | 1060 | if (!empty($field['title'])) {
|
1058 |
| -if ( $field['type'] == 'text' ) { |
1059 |
| - $th = '<label for="'. $field['id'] .'-'. $field['type'] .'">'. $field['title'] . $default_mark .'</label>'; |
1060 |
| -} else { |
1061 |
| -$th = $field['title'] . $default_mark; |
1062 |
| -} |
| 1061 | + $th = $field['title'] . $default_mark; |
1063 | 1062 | }
|
1064 | 1063 | if( isset( $field['subtitle'] ) ) {
|
1065 | 1064 | $th .= '<span class="description">' . $field['subtitle'] . '</span>';
|
@@ -1438,15 +1437,15 @@ public function _options_page_html() {
|
1438 | 1437 | // Warning bar
|
1439 | 1438 | if( isset( $_GET['settings-updated'] ) && $_GET['settings-updated'] == 'true' && $saved == '1' ) {
|
1440 | 1439 | if( isset( $this->options['REDUX_imported'] ) && $this->options['REDUX_imported'] === 1 ) {
|
1441 |
| - echo '<div id="redux-imported">' . apply_filters( 'redux-imported-text-' . $this->args['opt_name'], '' . __( '<strong>Settings Imported!</strong>', 'redux-framework' ) ) . '</div>'; |
| 1440 | + echo '<div id="redux-imported">' . apply_filters( 'redux-imported-text-' . $this->args['opt_name'], '<strong>' . __( 'Settings Imported!', 'redux-framework' ) ) . '</strong></div>'; |
1442 | 1441 | } else {
|
1443 |
| - echo '<div id="redux-save">' . apply_filters( 'redux-saved-text-' . $this->args['opt_name'], __( '<strong>Settings Saved!</strong>', 'redux-framework' ) ) . '</div>'; |
| 1442 | + echo '<div id="redux-save">' . apply_filters( 'redux-saved-text-' . $this->args['opt_name'], '<strong>'.__( 'Settings Saved!', 'redux-framework' ) ) . '</strong></div>'; |
1444 | 1443 | }
|
1445 | 1444 | }
|
1446 | 1445 |
|
1447 |
| - echo '<div id="redux-save-warn">' . apply_filters( 'redux-changed-text-' . $this->args['opt_name'], __( '<strong>Settings have changed, you should save them!</strong>', 'redux-framework' ) ) . '</div>'; |
1448 |
| - echo '<div id="redux-field-errors">' . __( '<strong><span></span> error(s) were found!</strong>', 'redux-framework' ) . '</div>'; |
1449 |
| - echo '<div id="redux-field-warnings">' . __( '<strong><span></span> warning(s) were found!</strong>', 'redux-framework' ) . '</div>'; |
| 1446 | + echo '<div id="redux-save-warn">' . apply_filters( 'redux-changed-text-' . $this->args['opt_name'], '<strong>'.__( 'Settings have changed, you should save them!', 'redux-framework' ) ) . '</strong></div>'; |
| 1447 | + echo '<div id="redux-field-errors"><strong><span></span> ' . __( 'error(s) were found!', 'redux-framework' ) . '</strong></div>'; |
| 1448 | + echo '<div id="redux-field-warnings"><strong><span></span> ' . __( 'warning(s) were found!', 'redux-framework' ) . '</strong></div>'; |
1450 | 1449 |
|
1451 | 1450 | echo '</div>';
|
1452 | 1451 |
|
|
0 commit comments