Version Description
- add textdomain loader
- add plugin header i18n
Download this release
Release Info
Developer | nathanrice |
Plugin | Genesis Simple Edits |
Version | 2.1.3 |
Comparing to | |
See all releases |
Code changes from version 2.1.2 to 2.1.3
- package.json +16 -16
- plugin.php +71 -62
- readme.txt +5 -1
package.json
CHANGED
@@ -7,21 +7,21 @@
|
|
7 |
},
|
8 |
"dependencies": {},
|
9 |
"devDependencies": {
|
10 |
-
"grunt": "
|
11 |
-
"grunt-autoprefixer": "
|
12 |
-
"grunt-checktextdomain": "
|
13 |
-
"grunt-contrib-cssmin": "
|
14 |
-
"grunt-contrib-imagemin": "
|
15 |
-
"grunt-contrib-jshint": "
|
16 |
-
"grunt-contrib-uglify": "
|
17 |
-
"grunt-contrib-watch": "
|
18 |
-
"grunt-csscomb": "
|
19 |
-
"grunt-jsbeautifier": "
|
20 |
-
"grunt-jsvalidate": "
|
21 |
-
"grunt-phplint": "
|
22 |
-
"grunt-styledocco": "
|
23 |
-
"grunt-wp-i18n": "
|
24 |
-
"load-grunt-tasks": "
|
25 |
},
|
26 |
"plugin": {
|
27 |
"name": "Genesis Simple Edits",
|
@@ -29,7 +29,7 @@
|
|
29 |
"description": "Genesis Simple Edits lets you edit the three most commonly modified areas in any Genesis theme: the post-info, the post-meta, and the footer area.",
|
30 |
"author": "StudioPress",
|
31 |
"authoruri": "http://www.studiopress.com/",
|
32 |
-
"version": "2.1.
|
33 |
"license": "GPL-2.0+",
|
34 |
"licenseuri": "http://www.gnu.org/licenses/gpl-2.0.html",
|
35 |
"textdomain": "genesis-simple-edits"
|
7 |
},
|
8 |
"dependencies": {},
|
9 |
"devDependencies": {
|
10 |
+
"grunt": "*",
|
11 |
+
"grunt-autoprefixer": "*",
|
12 |
+
"grunt-checktextdomain": "*",
|
13 |
+
"grunt-contrib-cssmin": "*",
|
14 |
+
"grunt-contrib-imagemin": "*",
|
15 |
+
"grunt-contrib-jshint": "*",
|
16 |
+
"grunt-contrib-uglify": "*",
|
17 |
+
"grunt-contrib-watch": "*",
|
18 |
+
"grunt-csscomb": "*",
|
19 |
+
"grunt-jsbeautifier": "*",
|
20 |
+
"grunt-jsvalidate": "*",
|
21 |
+
"grunt-phplint": "*",
|
22 |
+
"grunt-styledocco": "*",
|
23 |
+
"grunt-wp-i18n": "*",
|
24 |
+
"load-grunt-tasks": "*"
|
25 |
},
|
26 |
"plugin": {
|
27 |
"name": "Genesis Simple Edits",
|
29 |
"description": "Genesis Simple Edits lets you edit the three most commonly modified areas in any Genesis theme: the post-info, the post-meta, and the footer area.",
|
30 |
"author": "StudioPress",
|
31 |
"authoruri": "http://www.studiopress.com/",
|
32 |
+
"version": "2.1.3",
|
33 |
"license": "GPL-2.0+",
|
34 |
"licenseuri": "http://www.gnu.org/licenses/gpl-2.0.html",
|
35 |
"textdomain": "genesis-simple-edits"
|
plugin.php
CHANGED
@@ -6,7 +6,10 @@
|
|
6 |
Author: Nathan Rice
|
7 |
Author URI: http://www.nathanrice.net/
|
8 |
|
9 |
-
Version: 2.1.
|
|
|
|
|
|
|
10 |
|
11 |
License: GNU General Public License v2.0 (or later)
|
12 |
License URI: http://www.opensource.org/licenses/gpl-license.php
|
@@ -19,50 +22,56 @@
|
|
19 |
* @since 1.0
|
20 |
*/
|
21 |
class Genesis_Simple_Edits {
|
22 |
-
|
23 |
/** Constructor */
|
24 |
function __construct() {
|
25 |
-
|
26 |
register_activation_hook( __FILE__, array( $this, 'activation_hook' ) );
|
27 |
-
|
28 |
define( 'GSE_SETTINGS_FIELD', 'gse-settings' );
|
29 |
-
|
|
|
|
|
30 |
add_action( 'admin_init', array( $this, 'javascript' ) );
|
31 |
add_action( 'admin_init', array( $this, 'reset' ) );
|
32 |
add_action( 'admin_init', array( $this, 'register_settings' ) );
|
33 |
add_action( 'admin_menu', array( $this, 'add_menu' ), 15 );
|
34 |
add_action( 'admin_notices', array( $this, 'notices' ) );
|
35 |
-
|
36 |
add_filter( 'genesis_post_info', array( $this, 'post_info_filter' ), 20 );
|
37 |
add_filter( 'genesis_post_meta', array( $this, 'post_meta_filter' ), 20 );
|
38 |
add_filter( 'genesis_footer_backtotop_text', array( $this, 'footer_backtotop_filter' ), 20 );
|
39 |
add_filter( 'genesis_footer_creds_text', array( $this, 'footer_creds_filter' ), 20 );
|
40 |
add_filter( 'genesis_footer_output', array( $this, 'footer_output_filter' ), 20 );
|
41 |
-
|
42 |
}
|
43 |
-
|
44 |
function activation_hook() {
|
45 |
|
46 |
if ( ! defined( 'PARENT_THEME_VERSION' ) || ! version_compare( PARENT_THEME_VERSION, '2.1.0', '>=' ) ) {
|
47 |
deactivate_plugins( plugin_basename( __FILE__ ) ); /** Deactivate ourself */
|
48 |
wp_die( sprintf( __( 'Sorry, you cannot activate without <a href="%s">Genesis %s</a> or greater', 'genesis-simple-edits' ), 'http://my.studiopress.com/?download_id=91046d629e74d525b3f2978e404e7ffa', '2.1.0' ) );
|
49 |
}
|
50 |
-
|
|
|
|
|
|
|
|
|
51 |
}
|
52 |
-
|
53 |
function javascript() {
|
54 |
-
|
55 |
wp_enqueue_script( 'genesis-simple-edits-js', plugin_dir_url(__FILE__) . 'js/admin.js', array( 'jquery' ), '2.1.0', true );
|
56 |
-
|
57 |
}
|
58 |
-
|
59 |
function register_settings() {
|
60 |
register_setting( GSE_SETTINGS_FIELD, GSE_SETTINGS_FIELD );
|
61 |
add_option( GSE_SETTINGS_FIELD, $this->settings_defaults() );
|
62 |
}
|
63 |
-
|
64 |
function reset() {
|
65 |
-
|
66 |
if ( ! isset( $_REQUEST['page'] ) || 'genesis-simple-edits' != $_REQUEST['page'] )
|
67 |
return;
|
68 |
|
@@ -71,28 +80,28 @@ class Genesis_Simple_Edits {
|
|
71 |
wp_redirect( admin_url( 'admin.php?page=genesis-simple-edits&reset=true' ) );
|
72 |
exit;
|
73 |
}
|
74 |
-
|
75 |
}
|
76 |
-
|
77 |
function notices() {
|
78 |
-
|
79 |
if ( ! isset( $_REQUEST['page'] ) || 'genesis-simple-edits' != $_REQUEST['page'] )
|
80 |
return;
|
81 |
|
82 |
if ( isset( $_REQUEST['reset'] ) && 'true' == $_REQUEST['reset'] ) {
|
83 |
echo '<div id="message" class="updated"><p><strong>' . __( 'Simple Edits Reset', 'genesis-simple-edits' ) . '</strong></p></div>';
|
84 |
}
|
85 |
-
elseif ( isset( $_REQUEST['updated'] ) && 'true' == $_REQUEST['updated'] ) {
|
86 |
echo '<div id="message" class="updated"><p><strong>' . __( 'Simple Edits Saved', 'genesis-simple-edits' ) . '</strong></p></div>';
|
87 |
}
|
88 |
-
|
89 |
}
|
90 |
-
|
91 |
function settings_defaults() {
|
92 |
|
93 |
$footer_html5 = sprintf( '<p>[footer_copyright before="%s "] · [footer_childtheme_link before="" after=" %s"] [footer_genesis_link url="http://www.studiopress.com/" before=""] · [footer_wordpress_link] · [footer_loginout]</p>', __( 'Copyright', 'genesis-simple-edits' ), __( 'On', 'genesis-simple-edits' ) );
|
94 |
$footer_xhtml = '<div class="gototop"><p>[footer_backtotop]</p></div><div class="creds"><p>' . __( 'Copyright', 'genesis-simple-edits' ) . ' [footer_copyright] [footer_childtheme_link] · [footer_genesis_link] [footer_studiopress_link] · [footer_wordpress_link] · [footer_loginout]</p></div>';
|
95 |
-
|
96 |
return array(
|
97 |
'post_info' => '[post_date] ' . __( 'By', 'genesis-simple-edits' ) . ' [post_author_posts_link] [post_comments] [post_edit]',
|
98 |
'post_meta' => '[post_categories] [post_tags]',
|
@@ -101,42 +110,42 @@ class Genesis_Simple_Edits {
|
|
101 |
'footer_output_on' => 0,
|
102 |
'footer_output' => current_theme_supports( 'html5' ) ? $footer_html5 : $footer_xhtml,
|
103 |
);
|
104 |
-
|
105 |
}
|
106 |
-
|
107 |
function add_menu() {
|
108 |
-
|
109 |
add_submenu_page( 'genesis', __( 'Genesis - Simple Edits', 'genesis-simple-edits' ), __( 'Simple Edits','genesis-simple-edits' ), 'manage_options', 'genesis-simple-edits', array( &$this, 'admin_page' ) );
|
110 |
-
|
111 |
}
|
112 |
-
|
113 |
function admin_page() { ?>
|
114 |
-
|
115 |
<div class="wrap">
|
116 |
<form method="post" action="options.php">
|
117 |
<?php settings_fields( GSE_SETTINGS_FIELD ); // important! ?>
|
118 |
-
|
119 |
<h2><?php echo esc_html( get_admin_page_title() ); ?></h2>
|
120 |
-
|
121 |
<table class="form-table"><tbody>
|
122 |
-
|
123 |
<tr>
|
124 |
<th scope="row"><p><label for="<?php echo GSE_SETTINGS_FIELD; ?>[post_info]"><b><?php _e( 'Entry Meta (above content)', 'genesis-simple-edits' ); ?></b></label></p></th>
|
125 |
<td>
|
126 |
<p><input type="text" name="<?php echo GSE_SETTINGS_FIELD; ?>[post_info]" id="<?php echo GSE_SETTINGS_FIELD; ?>[post_info]" value="<?php echo esc_attr( genesis_get_option( 'post_info', GSE_SETTINGS_FIELD ) ); ?>" size="125" /></p>
|
127 |
</td>
|
128 |
</tr>
|
129 |
-
|
130 |
<tr>
|
131 |
<th scope="row"><p><label for="<?php echo GSE_SETTINGS_FIELD; ?>[post_meta]"><b><?php _e( 'Entry Meta (below content)', 'genesis-simple-edits' ); ?></b></label></p></th>
|
132 |
<td>
|
133 |
<p><input type="text" name="<?php echo GSE_SETTINGS_FIELD; ?>[post_meta]" id="<?php echo GSE_SETTINGS_FIELD; ?>[post_meta]" value="<?php echo esc_attr( genesis_get_option( 'post_meta', GSE_SETTINGS_FIELD ) ); ?>" size="125" /></p>
|
134 |
-
|
135 |
<p><small><a class="post-shortcodes-toggle" href="#"><?php _e( 'Show available entry meta shortcodes', 'genesis-simple-edits' ) ?></a></small></p>
|
136 |
-
|
137 |
</td>
|
138 |
</tr>
|
139 |
-
|
140 |
<tr class="post-shortcodes" style="display: none;">
|
141 |
<th scope="row"><p><span class="description"><?php _e( 'Shortcode Reference', 'genesis-simple-edits' ); ?></span></p></th>
|
142 |
<td>
|
@@ -167,27 +176,27 @@ class Genesis_Simple_Edits {
|
|
167 |
</td>
|
168 |
</tr>
|
169 |
<?php endif; ?>
|
170 |
-
|
171 |
<tr>
|
172 |
<th scope="row"><p><label for="<?php echo GSE_SETTINGS_FIELD; ?>[footer_creds_text]"><b><?php _e( 'Footer Credits Text', 'genesis-simple-edits' ); ?></b></label></p></th>
|
173 |
<td>
|
174 |
<p><input type="text" name="<?php echo GSE_SETTINGS_FIELD; ?>[footer_creds_text]" id="<?php echo GSE_SETTINGS_FIELD; ?>[footer_creds_text]" value="<?php echo esc_attr( genesis_get_option( 'footer_creds_text', GSE_SETTINGS_FIELD ) ); ?>" size="125" /></p>
|
175 |
</td>
|
176 |
</tr>
|
177 |
-
|
178 |
<tr>
|
179 |
<th scope="row"><p><b><?php _e( 'Footer Output', 'genesis-simple-edits' ); ?></b></p></th>
|
180 |
<td>
|
181 |
<p><input type="checkbox" name="<?php echo GSE_SETTINGS_FIELD; ?>[footer_output_on]" id="<?php echo GSE_SETTINGS_FIELD; ?>[footer_output_on]" value="1" <?php checked( 1, genesis_get_option( 'footer_output_on', GSE_SETTINGS_FIELD ) ); ?> /> <label for="<?php echo GSE_SETTINGS_FIELD; ?>[footer_output_on]"><?php _e( 'Modify Entire Footer Text (including markup)?', 'genesis-simple-edits' ); ?></label></p>
|
182 |
-
|
183 |
<p><span class="description"><?php _e( 'NOTE: Checking this option will use the content of the box below, and override the options above.', 'genesis-simple-edits' ); ?></span></p>
|
184 |
-
|
185 |
<p><textarea name="<?php echo GSE_SETTINGS_FIELD; ?>[footer_output]" cols="80" rows="5"><?php echo esc_textarea( genesis_get_option( 'footer_output', GSE_SETTINGS_FIELD ) ); ?></textarea></p>
|
186 |
-
|
187 |
<p><small><a class="footer-shortcodes-toggle" href="#"><?php _e( 'Show available footer shortcodes', 'genesis-simple-edits' ); ?></a></small></p>
|
188 |
</td>
|
189 |
</tr>
|
190 |
-
|
191 |
<tr class="footer-shortcodes" style="display: none;">
|
192 |
<th scope="row"><p><span class="description"><?php _e( 'Shortcode Reference', 'genesis-simple-edits' ); ?></span></p></th>
|
193 |
<td>
|
@@ -207,52 +216,52 @@ class Genesis_Simple_Edits {
|
|
207 |
</p>
|
208 |
</td>
|
209 |
</tr>
|
210 |
-
|
211 |
</tbody></table>
|
212 |
-
|
213 |
<div class="bottom-buttons">
|
214 |
<input type="submit" class="button-primary" value="<?php _e( 'Save Settings', 'genesis-simple-edits' ); ?>" />
|
215 |
<input type="submit" class="button-secondary" name="<?php echo GSE_SETTINGS_FIELD; ?>[reset]" value="<?php _e( 'Reset Settings', 'genesis-simple-edits' ); ?>" />
|
216 |
</div>
|
217 |
-
|
218 |
</form>
|
219 |
</div>
|
220 |
-
|
221 |
<?php }
|
222 |
-
|
223 |
function post_info_filter( $output ) {
|
224 |
-
|
225 |
return genesis_get_option( 'post_info', GSE_SETTINGS_FIELD );
|
226 |
-
|
227 |
}
|
228 |
-
|
229 |
function post_meta_filter( $output ) {
|
230 |
-
|
231 |
return genesis_get_option( 'post_meta', GSE_SETTINGS_FIELD );
|
232 |
-
|
233 |
}
|
234 |
-
|
235 |
function footer_backtotop_filter( $output ) {
|
236 |
-
|
237 |
return genesis_get_option( 'footer_backtotop_text', GSE_SETTINGS_FIELD );
|
238 |
-
|
239 |
}
|
240 |
-
|
241 |
function footer_creds_filter( $output ) {
|
242 |
-
|
243 |
return genesis_get_option( 'footer_creds_text', GSE_SETTINGS_FIELD );
|
244 |
-
|
245 |
}
|
246 |
-
|
247 |
function footer_output_filter( $output ) {
|
248 |
-
|
249 |
if ( genesis_get_option( 'footer_output_on', GSE_SETTINGS_FIELD ) )
|
250 |
return genesis_get_option( 'footer_output', GSE_SETTINGS_FIELD );
|
251 |
-
|
252 |
return $output;
|
253 |
-
|
254 |
}
|
255 |
-
|
256 |
}
|
257 |
|
258 |
$Genesis_Simple_Edits = new Genesis_Simple_Edits;
|
6 |
Author: Nathan Rice
|
7 |
Author URI: http://www.nathanrice.net/
|
8 |
|
9 |
+
Version: 2.1.3
|
10 |
+
|
11 |
+
Text Domain: genesis-simple-edits
|
12 |
+
Domain Path: /languages
|
13 |
|
14 |
License: GNU General Public License v2.0 (or later)
|
15 |
License URI: http://www.opensource.org/licenses/gpl-license.php
|
22 |
* @since 1.0
|
23 |
*/
|
24 |
class Genesis_Simple_Edits {
|
25 |
+
|
26 |
/** Constructor */
|
27 |
function __construct() {
|
28 |
+
|
29 |
register_activation_hook( __FILE__, array( $this, 'activation_hook' ) );
|
30 |
+
|
31 |
define( 'GSE_SETTINGS_FIELD', 'gse-settings' );
|
32 |
+
|
33 |
+
add_action( 'plugins_loaded', 'load_textdomain' );
|
34 |
+
|
35 |
add_action( 'admin_init', array( $this, 'javascript' ) );
|
36 |
add_action( 'admin_init', array( $this, 'reset' ) );
|
37 |
add_action( 'admin_init', array( $this, 'register_settings' ) );
|
38 |
add_action( 'admin_menu', array( $this, 'add_menu' ), 15 );
|
39 |
add_action( 'admin_notices', array( $this, 'notices' ) );
|
40 |
+
|
41 |
add_filter( 'genesis_post_info', array( $this, 'post_info_filter' ), 20 );
|
42 |
add_filter( 'genesis_post_meta', array( $this, 'post_meta_filter' ), 20 );
|
43 |
add_filter( 'genesis_footer_backtotop_text', array( $this, 'footer_backtotop_filter' ), 20 );
|
44 |
add_filter( 'genesis_footer_creds_text', array( $this, 'footer_creds_filter' ), 20 );
|
45 |
add_filter( 'genesis_footer_output', array( $this, 'footer_output_filter' ), 20 );
|
46 |
+
|
47 |
}
|
48 |
+
|
49 |
function activation_hook() {
|
50 |
|
51 |
if ( ! defined( 'PARENT_THEME_VERSION' ) || ! version_compare( PARENT_THEME_VERSION, '2.1.0', '>=' ) ) {
|
52 |
deactivate_plugins( plugin_basename( __FILE__ ) ); /** Deactivate ourself */
|
53 |
wp_die( sprintf( __( 'Sorry, you cannot activate without <a href="%s">Genesis %s</a> or greater', 'genesis-simple-edits' ), 'http://my.studiopress.com/?download_id=91046d629e74d525b3f2978e404e7ffa', '2.1.0' ) );
|
54 |
}
|
55 |
+
|
56 |
+
}
|
57 |
+
|
58 |
+
function load_textdomain() {
|
59 |
+
load_plugin_textdomain( 'genesis-simple-edits', false, plugin_basename( dirname( __FILE__ ) ) . '/languages' );
|
60 |
}
|
61 |
+
|
62 |
function javascript() {
|
63 |
+
|
64 |
wp_enqueue_script( 'genesis-simple-edits-js', plugin_dir_url(__FILE__) . 'js/admin.js', array( 'jquery' ), '2.1.0', true );
|
65 |
+
|
66 |
}
|
67 |
+
|
68 |
function register_settings() {
|
69 |
register_setting( GSE_SETTINGS_FIELD, GSE_SETTINGS_FIELD );
|
70 |
add_option( GSE_SETTINGS_FIELD, $this->settings_defaults() );
|
71 |
}
|
72 |
+
|
73 |
function reset() {
|
74 |
+
|
75 |
if ( ! isset( $_REQUEST['page'] ) || 'genesis-simple-edits' != $_REQUEST['page'] )
|
76 |
return;
|
77 |
|
80 |
wp_redirect( admin_url( 'admin.php?page=genesis-simple-edits&reset=true' ) );
|
81 |
exit;
|
82 |
}
|
83 |
+
|
84 |
}
|
85 |
+
|
86 |
function notices() {
|
87 |
+
|
88 |
if ( ! isset( $_REQUEST['page'] ) || 'genesis-simple-edits' != $_REQUEST['page'] )
|
89 |
return;
|
90 |
|
91 |
if ( isset( $_REQUEST['reset'] ) && 'true' == $_REQUEST['reset'] ) {
|
92 |
echo '<div id="message" class="updated"><p><strong>' . __( 'Simple Edits Reset', 'genesis-simple-edits' ) . '</strong></p></div>';
|
93 |
}
|
94 |
+
elseif ( isset( $_REQUEST['updated'] ) && 'true' == $_REQUEST['updated'] ) {
|
95 |
echo '<div id="message" class="updated"><p><strong>' . __( 'Simple Edits Saved', 'genesis-simple-edits' ) . '</strong></p></div>';
|
96 |
}
|
97 |
+
|
98 |
}
|
99 |
+
|
100 |
function settings_defaults() {
|
101 |
|
102 |
$footer_html5 = sprintf( '<p>[footer_copyright before="%s "] · [footer_childtheme_link before="" after=" %s"] [footer_genesis_link url="http://www.studiopress.com/" before=""] · [footer_wordpress_link] · [footer_loginout]</p>', __( 'Copyright', 'genesis-simple-edits' ), __( 'On', 'genesis-simple-edits' ) );
|
103 |
$footer_xhtml = '<div class="gototop"><p>[footer_backtotop]</p></div><div class="creds"><p>' . __( 'Copyright', 'genesis-simple-edits' ) . ' [footer_copyright] [footer_childtheme_link] · [footer_genesis_link] [footer_studiopress_link] · [footer_wordpress_link] · [footer_loginout]</p></div>';
|
104 |
+
|
105 |
return array(
|
106 |
'post_info' => '[post_date] ' . __( 'By', 'genesis-simple-edits' ) . ' [post_author_posts_link] [post_comments] [post_edit]',
|
107 |
'post_meta' => '[post_categories] [post_tags]',
|
110 |
'footer_output_on' => 0,
|
111 |
'footer_output' => current_theme_supports( 'html5' ) ? $footer_html5 : $footer_xhtml,
|
112 |
);
|
113 |
+
|
114 |
}
|
115 |
+
|
116 |
function add_menu() {
|
117 |
+
|
118 |
add_submenu_page( 'genesis', __( 'Genesis - Simple Edits', 'genesis-simple-edits' ), __( 'Simple Edits','genesis-simple-edits' ), 'manage_options', 'genesis-simple-edits', array( &$this, 'admin_page' ) );
|
119 |
+
|
120 |
}
|
121 |
+
|
122 |
function admin_page() { ?>
|
123 |
+
|
124 |
<div class="wrap">
|
125 |
<form method="post" action="options.php">
|
126 |
<?php settings_fields( GSE_SETTINGS_FIELD ); // important! ?>
|
127 |
+
|
128 |
<h2><?php echo esc_html( get_admin_page_title() ); ?></h2>
|
129 |
+
|
130 |
<table class="form-table"><tbody>
|
131 |
+
|
132 |
<tr>
|
133 |
<th scope="row"><p><label for="<?php echo GSE_SETTINGS_FIELD; ?>[post_info]"><b><?php _e( 'Entry Meta (above content)', 'genesis-simple-edits' ); ?></b></label></p></th>
|
134 |
<td>
|
135 |
<p><input type="text" name="<?php echo GSE_SETTINGS_FIELD; ?>[post_info]" id="<?php echo GSE_SETTINGS_FIELD; ?>[post_info]" value="<?php echo esc_attr( genesis_get_option( 'post_info', GSE_SETTINGS_FIELD ) ); ?>" size="125" /></p>
|
136 |
</td>
|
137 |
</tr>
|
138 |
+
|
139 |
<tr>
|
140 |
<th scope="row"><p><label for="<?php echo GSE_SETTINGS_FIELD; ?>[post_meta]"><b><?php _e( 'Entry Meta (below content)', 'genesis-simple-edits' ); ?></b></label></p></th>
|
141 |
<td>
|
142 |
<p><input type="text" name="<?php echo GSE_SETTINGS_FIELD; ?>[post_meta]" id="<?php echo GSE_SETTINGS_FIELD; ?>[post_meta]" value="<?php echo esc_attr( genesis_get_option( 'post_meta', GSE_SETTINGS_FIELD ) ); ?>" size="125" /></p>
|
143 |
+
|
144 |
<p><small><a class="post-shortcodes-toggle" href="#"><?php _e( 'Show available entry meta shortcodes', 'genesis-simple-edits' ) ?></a></small></p>
|
145 |
+
|
146 |
</td>
|
147 |
</tr>
|
148 |
+
|
149 |
<tr class="post-shortcodes" style="display: none;">
|
150 |
<th scope="row"><p><span class="description"><?php _e( 'Shortcode Reference', 'genesis-simple-edits' ); ?></span></p></th>
|
151 |
<td>
|
176 |
</td>
|
177 |
</tr>
|
178 |
<?php endif; ?>
|
179 |
+
|
180 |
<tr>
|
181 |
<th scope="row"><p><label for="<?php echo GSE_SETTINGS_FIELD; ?>[footer_creds_text]"><b><?php _e( 'Footer Credits Text', 'genesis-simple-edits' ); ?></b></label></p></th>
|
182 |
<td>
|
183 |
<p><input type="text" name="<?php echo GSE_SETTINGS_FIELD; ?>[footer_creds_text]" id="<?php echo GSE_SETTINGS_FIELD; ?>[footer_creds_text]" value="<?php echo esc_attr( genesis_get_option( 'footer_creds_text', GSE_SETTINGS_FIELD ) ); ?>" size="125" /></p>
|
184 |
</td>
|
185 |
</tr>
|
186 |
+
|
187 |
<tr>
|
188 |
<th scope="row"><p><b><?php _e( 'Footer Output', 'genesis-simple-edits' ); ?></b></p></th>
|
189 |
<td>
|
190 |
<p><input type="checkbox" name="<?php echo GSE_SETTINGS_FIELD; ?>[footer_output_on]" id="<?php echo GSE_SETTINGS_FIELD; ?>[footer_output_on]" value="1" <?php checked( 1, genesis_get_option( 'footer_output_on', GSE_SETTINGS_FIELD ) ); ?> /> <label for="<?php echo GSE_SETTINGS_FIELD; ?>[footer_output_on]"><?php _e( 'Modify Entire Footer Text (including markup)?', 'genesis-simple-edits' ); ?></label></p>
|
191 |
+
|
192 |
<p><span class="description"><?php _e( 'NOTE: Checking this option will use the content of the box below, and override the options above.', 'genesis-simple-edits' ); ?></span></p>
|
193 |
+
|
194 |
<p><textarea name="<?php echo GSE_SETTINGS_FIELD; ?>[footer_output]" cols="80" rows="5"><?php echo esc_textarea( genesis_get_option( 'footer_output', GSE_SETTINGS_FIELD ) ); ?></textarea></p>
|
195 |
+
|
196 |
<p><small><a class="footer-shortcodes-toggle" href="#"><?php _e( 'Show available footer shortcodes', 'genesis-simple-edits' ); ?></a></small></p>
|
197 |
</td>
|
198 |
</tr>
|
199 |
+
|
200 |
<tr class="footer-shortcodes" style="display: none;">
|
201 |
<th scope="row"><p><span class="description"><?php _e( 'Shortcode Reference', 'genesis-simple-edits' ); ?></span></p></th>
|
202 |
<td>
|
216 |
</p>
|
217 |
</td>
|
218 |
</tr>
|
219 |
+
|
220 |
</tbody></table>
|
221 |
+
|
222 |
<div class="bottom-buttons">
|
223 |
<input type="submit" class="button-primary" value="<?php _e( 'Save Settings', 'genesis-simple-edits' ); ?>" />
|
224 |
<input type="submit" class="button-secondary" name="<?php echo GSE_SETTINGS_FIELD; ?>[reset]" value="<?php _e( 'Reset Settings', 'genesis-simple-edits' ); ?>" />
|
225 |
</div>
|
226 |
+
|
227 |
</form>
|
228 |
</div>
|
229 |
+
|
230 |
<?php }
|
231 |
+
|
232 |
function post_info_filter( $output ) {
|
233 |
+
|
234 |
return genesis_get_option( 'post_info', GSE_SETTINGS_FIELD );
|
235 |
+
|
236 |
}
|
237 |
+
|
238 |
function post_meta_filter( $output ) {
|
239 |
+
|
240 |
return genesis_get_option( 'post_meta', GSE_SETTINGS_FIELD );
|
241 |
+
|
242 |
}
|
243 |
+
|
244 |
function footer_backtotop_filter( $output ) {
|
245 |
+
|
246 |
return genesis_get_option( 'footer_backtotop_text', GSE_SETTINGS_FIELD );
|
247 |
+
|
248 |
}
|
249 |
+
|
250 |
function footer_creds_filter( $output ) {
|
251 |
+
|
252 |
return genesis_get_option( 'footer_creds_text', GSE_SETTINGS_FIELD );
|
253 |
+
|
254 |
}
|
255 |
+
|
256 |
function footer_output_filter( $output ) {
|
257 |
+
|
258 |
if ( genesis_get_option( 'footer_output_on', GSE_SETTINGS_FIELD ) )
|
259 |
return genesis_get_option( 'footer_output', GSE_SETTINGS_FIELD );
|
260 |
+
|
261 |
return $output;
|
262 |
+
|
263 |
}
|
264 |
+
|
265 |
}
|
266 |
|
267 |
$Genesis_Simple_Edits = new Genesis_Simple_Edits;
|
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_i
|
|
4 |
Tags: shortcodes, genesis, genesiswp, studiopress
|
5 |
Requires at least: 3.2
|
6 |
Tested up to: 4.3.1
|
7 |
-
Stable tag: 2.1.
|
8 |
|
9 |
This plugin lets you edit the three most commonly modified areas in any Genesis theme: the post-info (byline), the post-meta, and the footer area.
|
10 |
|
@@ -37,6 +37,10 @@ You must have Genesis (1.3+) or a Genesis child theme installed and activated on
|
|
37 |
|
38 |
== Changelog ==
|
39 |
|
|
|
|
|
|
|
|
|
40 |
= 2.1.2 =
|
41 |
* Generate POT
|
42 |
|
4 |
Tags: shortcodes, genesis, genesiswp, studiopress
|
5 |
Requires at least: 3.2
|
6 |
Tested up to: 4.3.1
|
7 |
+
Stable tag: 2.1.3
|
8 |
|
9 |
This plugin lets you edit the three most commonly modified areas in any Genesis theme: the post-info (byline), the post-meta, and the footer area.
|
10 |
|
37 |
|
38 |
== Changelog ==
|
39 |
|
40 |
+
= 2.1.3 =
|
41 |
+
* add textdomain loader
|
42 |
+
* add plugin header i18n
|
43 |
+
|
44 |
= 2.1.2 =
|
45 |
* Generate POT
|
46 |
|