PluginProbe
Juicer.io: Effortlessly embed, curate, and aggregate social media feeds into your website / 1.11
Juicer.io: Effortlessly embed, curate, and aggregate social media feeds into your website v1.11
1.13.0 1.12.18 1.12.5 1.12.6 1.12.7 1.12.8 1.12.9 1.2 1.3 1.3.1 1.4 1.4.1 1.5 1.6 1.6.1 1.7 1.7.1 1.7.2 1.8 1.9 1.9.2 1.9.3 1.9.4 1.9.5 1.9.6 All 46 releases
← All changes | juicer.php +17 -9 1.71.11 View file →
@@ -1,12 +1,12 @@
1 1 <?php
2 2 /**
3 3 * Plugin Name: Juicer
4 - * Plugin URI: http://www.juicer.io
5 - * Description: Add and embed a social media feed to your site with a shortcode.
6 - * Version: 1.7
7 - * Author: Ryan MacInnes
8 - * Author URI: http://www.goddamnyouryan.com
4 + * Plugin URI: https://wp.juicer.io
5 + * Description: Embed, curate & aggregate social media feeds from Instagram, Twitter, TikTok, Facebook, LinkedIn, YouTube, Slack, etc. and customize them as you like.
6 + * Version: 1.11
7 + * Author: saas.group LLC
8 + * Author URI: https://saas.group
9 9 * License: GPLv2 or later
10 10 */
11 11
12 12 /*
@@ -58,11 +58,11 @@
58 58 $map_attributes = generate_attributes($args);
59 59
60 60 $attributes = join(' ', $map_attributes);
61 61
62 - $output = '<ul class="juicer-feed" data-feed-id="' . $args['name'] . '" ' . $attributes . '>';
62 + $output = '<ul class="juicer-feed" data-origin="wp-plugin-1-11" data-feed-id="' . htmlspecialchars($args['name']) . '" ' . $attributes . '>';
63 63
64 - $closing = ($args['paid'] == 'true') ? '<ul>' : '<h1 class="referral"><a href="http://www.juicer.io">Powered by Juicer</a></h1></ul>';
64 + $closing = (array_key_exists('paid', $args)) ? '</ul>' : '<h1 class="referral"><a href="http://www.juicer.io">Powered by Juicer</a></h1></ul>';
65 65
66 66 $output = $output . $closing;
67 67
68 68 return $output;
@@ -73,10 +73,18 @@
73 73 function generate_attributes( $array ) {
74 74 $attrs = array();
75 75
76 76 foreach ( $array as $key => $val ) {
77 - if ( !empty($val) ) {
78 - array_push($attrs, 'data-' . $key . '="' . $val . '"');
77 + if ( $key == 'name' ) {
78 + continue;
79 + }
80 + $escaped_val = htmlspecialchars($val);
81 + if ( !empty($escaped_val) ) {
82 + if (strpos($escaped_val, 'data-') !== false) {
83 + array_push($attrs, $escaped_val);
84 + } else {
85 + array_push($attrs, 'data-' . $key . '="' . $escaped_val . '"');
86 + }
79 87 }
80 88 }
81 89
82 90 return $attrs;