From 93de47d5390c9bd433ae1fc22bd552d35ac8987e Mon Sep 17 00:00:00 2001 From: Nicolas Laruelle Date: Thu, 21 Jul 2016 16:08:21 +0700 Subject: [PATCH 1/4] add "markupType" to form.php to be able to change the

container to anything else "div", "h4"... (in a SEO way) --- includes/form.php | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/includes/form.php b/includes/form.php index a99226f..fc1580b 100644 --- a/includes/form.php +++ b/includes/form.php @@ -3,7 +3,7 @@ * Widget forms. * * @package Recent_Posts_Widget_Extended - * @since 0.9.4 + * @since 0.9.9.7 * @author Satrya * @copyright Copyright (c) 2014, Satrya * @license http://www.gnu.org/licenses/gpl-2.0.html @@ -27,6 +27,14 @@

+ + +

+ + +

From d242e58233bf17f700fe96dcc853466a86cc52ec Mon Sep 17 00:00:00 2001 From: Nicolas Laruelle Date: Thu, 21 Jul 2016 16:09:29 +0700 Subject: [PATCH 2/4] add "markupType" to function.php to be able to change the

container to anything else "div", "h4"... (in a SEO way) --- includes/functions.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/includes/functions.php b/includes/functions.php index a6e2978..a3ca861 100644 --- a/includes/functions.php +++ b/includes/functions.php @@ -3,7 +3,7 @@ * Various functions used by the plugin. * * @package Recent_Posts_Widget_Extended - * @since 0.9.4 + * @since 0.9.9.7 * @author Satrya * @copyright Copyright (c) 2014, Satrya * @license http://www.gnu.org/licenses/gpl-2.0.html @@ -50,6 +50,7 @@ function rpwe_get_default_args() { 'styles_default' => true, 'css' => $css_defaults, + 'markupType' => '', 'cssID' => '', 'css_class' => '', 'before' => '', @@ -167,7 +168,9 @@ function rpwe_get_recent_posts( $args = array() ) { endif; - $html .= '

' . esc_attr( get_the_title() ) . '

'; + if(empty($args['markupType'])) { $markupType = 'div'; } else { $markupType = $args['markupType']; } + + $html .= '<' . $markupType . ' class="rpwe-title">' . esc_attr( get_the_title() ) . ''; if ( $args['date'] ) : $date = get_the_date(); From edb4f6b7fe5a1151f1c2af162e880aef750df2f9 Mon Sep 17 00:00:00 2001 From: Nicolas Laruelle Date: Thu, 21 Jul 2016 16:10:48 +0700 Subject: [PATCH 3/4] add "markupType" to widget.php to be able to change the

container to anything else "div", "h4"... (in a SEO way) --- classes/widget.php | 1 + 1 file changed, 1 insertion(+) diff --git a/classes/widget.php b/classes/widget.php index 6f0b22f..24b02b8 100644 --- a/classes/widget.php +++ b/classes/widget.php @@ -128,6 +128,7 @@ public function update( $new_instance, $old_instance ) { $instance['styles_default'] = isset( $new_instance['styles_default'] ) ? (bool) $new_instance['styles_default'] : false; $instance['cssID'] = sanitize_html_class( $new_instance['cssID'] ); + $instance['markupType'] = sanitize_html_class( $new_instance['markupType'] ); $instance['css_class'] = sanitize_html_class( $new_instance['css_class'] ); $instance['css'] = $new_instance['css']; From 3685e870efb02c8f5372a4873cc2fa11ca169e2f Mon Sep 17 00:00:00 2001 From: Nicolas Laruelle Date: Thu, 21 Jul 2016 16:11:25 +0700 Subject: [PATCH 4/4] add "markupType" to rpwe.php to be able to change the

container to anything else "div", "h4"... (in a SEO way) --- rpwe.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rpwe.php b/rpwe.php index 33d986d..ddc5f3f 100644 --- a/rpwe.php +++ b/rpwe.php @@ -3,7 +3,7 @@ * Plugin Name: Recent Posts Widget Extended * Plugin URI: https://www.theme-junkie.com/plugins/recent-posts-widget-extended/ * Description: Enables advanced widget that gives you total control over the output of your site’s most recent Posts. - * Version: 0.9.9.6 + * Version: 0.9.9.7 * Author: Satrya * Author URI: https://www.theme-junkie.com/ * Author Email: support@theme-junkie.com @@ -135,4 +135,4 @@ function register_image_size() { } -new RPW_Extended; \ No newline at end of file +new RPW_Extended;