Version Description
[29/08/2019] * Nonce and permission check. * readme file text update.
Download this release
Release Info
Developer | weblizar |
Plugin | Weblizar Twitter Widget |
Version | 1.8.9 |
Comparing to | |
See all releases |
Code changes from version 1.8.8 to 1.8.9
- banner.php +1 -1
- our_product.php +1 -1
- readme.txt +4 -2
- twiiter_help.php +35 -24
- twiiter_help_body.php +4 -4
- twitter-tweets.php +2 -4
- twitter_tweets_widgets.php +12 -13
banner.php
CHANGED
@@ -28,4 +28,4 @@ $twt_imgpath = WEBLIZAR_TWITTER_PLUGIN_URL."images/twt.jpg"; ?>
|
|
28 |
</div>
|
29 |
</div>
|
30 |
</div>
|
31 |
-
</div>
|
28 |
</div>
|
29 |
</div>
|
30 |
</div>
|
31 |
+
</div>
|
our_product.php
CHANGED
@@ -17,7 +17,7 @@ $twt_imgpath = WEBLIZAR_TWITTER_PLUGIN_URL."images/twt.jpg";
|
|
17 |
<img class="card-img-top" src="<?php echo WEBLIZAR_TWITTER_PLUGIN_URL."images/feature/multifeed.jpg"; ?>" alt="">
|
18 |
<div class="card-body">
|
19 |
<h4 class="card-title"><?php esc_html_e( 'Twitter Tweets Widget', 'twitter-tweets' ); ?></h4>
|
20 |
-
</div>
|
21 |
</div>
|
22 |
</div>
|
23 |
<div class="col-md-4 feature-div">
|
17 |
<img class="card-img-top" src="<?php echo WEBLIZAR_TWITTER_PLUGIN_URL."images/feature/multifeed.jpg"; ?>" alt="">
|
18 |
<div class="card-body">
|
19 |
<h4 class="card-title"><?php esc_html_e( 'Twitter Tweets Widget', 'twitter-tweets' ); ?></h4>
|
20 |
+
</div>
|
21 |
</div>
|
22 |
</div>
|
23 |
<div class="col-md-4 feature-div">
|
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.weblizar.com/
|
|
4 |
Tags: twitter, tweets, twitter tweets, twitter widget, twitter wordPress plugin, twitter feed
|
5 |
Requires at least: 3.8
|
6 |
Tested up to: 5.2.2
|
7 |
-
Stable tag: 1.8.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -113,12 +113,14 @@ Please use WordPress support forum to ask any query regarding any issue.
|
|
113 |
|
114 |
For more information, see Weblizar(https://weblizar.com/)
|
115 |
|
|
|
|
|
|
|
116 |
|
117 |
= 1.8.8 =[28/08/2019]
|
118 |
* Some security issue fixed
|
119 |
* readme file text update.
|
120 |
|
121 |
-
|
122 |
= 1.8.7 =[27/08/2019]
|
123 |
* Plugin name change
|
124 |
* Some file text update
|
4 |
Tags: twitter, tweets, twitter tweets, twitter widget, twitter wordPress plugin, twitter feed
|
5 |
Requires at least: 3.8
|
6 |
Tested up to: 5.2.2
|
7 |
+
Stable tag: 1.8.9
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
113 |
|
114 |
For more information, see Weblizar(https://weblizar.com/)
|
115 |
|
116 |
+
= 1.8.9 =[29/08/2019]
|
117 |
+
* Nonce and permission check.
|
118 |
+
* readme file text update.
|
119 |
|
120 |
= 1.8.8 =[28/08/2019]
|
121 |
* Some security issue fixed
|
122 |
* readme file text update.
|
123 |
|
|
|
124 |
= 1.8.7 =[27/08/2019]
|
125 |
* Plugin name change
|
126 |
* Some file text update
|
twiiter_help.php
CHANGED
@@ -79,14 +79,18 @@ wp_enqueue_style('bootstrap', WEBLIZAR_TWITTER_PLUGIN_URL. 'css/bootstrap.min.cs
|
|
79 |
|
80 |
if(isset($_REQUEST['twitter-page-user_name'])) {
|
81 |
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
-
|
86 |
-
|
87 |
-
|
88 |
-
|
89 |
-
|
|
|
|
|
|
|
|
|
90 |
|
91 |
$TwitterSettingsArray = serialize(
|
92 |
array(
|
@@ -104,7 +108,12 @@ if(isset($_REQUEST['twitter-page-user_name'])) {
|
|
104 |
|
105 |
/* Twitter api key save */
|
106 |
|
107 |
-
if ( isset( $_REQUEST['wl_twitter_consumer_key'] ) && isset( $_REQUEST['twitter_api_nonce'] )
|
|
|
|
|
|
|
|
|
|
|
108 |
$wl_twitter_consumer_key = sanitize_text_field( $_REQUEST['wl_twitter_consumer_key'] );
|
109 |
$wl_twitter_consumer_secret = sanitize_text_field( $_REQUEST['wl_twitter_consumer_secret'] );
|
110 |
$wl_twitter_access_token = sanitize_text_field( $_REQUEST['wl_twitter_access_token'] );
|
@@ -170,6 +179,8 @@ if ( isset( $_REQUEST['wl_twitter_consumer_key'] ) && isset( $_REQUEST['twitter_
|
|
170 |
if ( isset( $twitterSettings[ 'tw_language' ] ) ) {
|
171 |
$tw_language = $twitterSettings[ 'tw_language' ];
|
172 |
}
|
|
|
|
|
173 |
?>
|
174 |
<p>
|
175 |
<label><?php esc_html_e( 'Twitter Account Username', 'twitter-tweets' ); ?></label>
|
@@ -192,30 +203,30 @@ if ( isset( $_REQUEST['wl_twitter_consumer_key'] ) && isset( $_REQUEST['twitter_
|
|
192 |
<label><?php esc_html_e( 'Height', 'twitter-tweets' ); ?></label>
|
193 |
<input class="widefat wltt-slider" id="twitter-page-url-Height" name="twitter-page-url-Height" type="range" value="<?php echo esc_attr($Height ); ?>" min="0" max="1500" data-rangeSlider>
|
194 |
</p>
|
195 |
-
<p><b
|
196 |
<br>
|
197 |
|
198 |
<p>
|
199 |
<label><?php esc_html_e( 'URL Link Color:', 'twitter-tweets' ); ?></label>
|
200 |
<input class="widefat wltt-color-field" id="twitter-page-lnk-Color" name="twitter-page-lnk-Color" type="text" value="<?php echo esc_attr( $LinkColor ); ?>" data-default-color="#effeff" >
|
201 |
|
202 |
-
Find More Color Codes <a href="http://html-color-codes.info/" target="_blank"
|
203 |
</p>
|
204 |
<br>
|
205 |
|
206 |
<p>
|
207 |
<label><?php esc_html_e( 'Exclude Replies on Tweets', 'twitter-tweets' ); ?></label>
|
208 |
<select id="exclude_replies_23" name="exclude_replies_23">
|
209 |
-
<option value="yes" <?php if($ExcludeReplies == "yes") echo "selected=selected"
|
210 |
-
<option value="no" <?php if($ExcludeReplies == "no") echo "selected=selected"
|
211 |
</select>
|
212 |
</p>
|
213 |
<br>
|
214 |
<p>
|
215 |
<label><?php esc_html_e( 'Auto Expand Photos in Tweets', 'twitter-tweets' ); ?></label>
|
216 |
<select id="photo_1234" name="photo_1234">
|
217 |
-
<option value="yes" <?php if($AutoExpandPhotos == "yes") echo "selected=selected"
|
218 |
-
<option value="no" <?php if($AutoExpandPhotos == "no") echo "selected=selected"
|
219 |
</select>
|
220 |
</p>
|
221 |
<br>
|
@@ -266,7 +277,7 @@ if ( isset( $_REQUEST['wl_twitter_consumer_key'] ) && isset( $_REQUEST['twitter_
|
|
266 |
<div id="fb-img" style="display: none;">
|
267 |
<img src="<?php echo WEBLIZAR_TWITTER_PLUGIN_URL.'images/loading.gif'; ?>" />
|
268 |
</div>
|
269 |
-
<div id="fb-msg" style="display: none;" class"alert">
|
270 |
<?php esc_html_e( 'Settings successfully saved. Reloading page for generating preview right side of setting.', 'twitter-tweets' ); ?>
|
271 |
</div>
|
272 |
</form>
|
@@ -275,7 +286,7 @@ if ( isset( $_REQUEST['wl_twitter_consumer_key'] ) && isset( $_REQUEST['twitter_
|
|
275 |
<!-- Preview Part-->
|
276 |
<div class="col-md-6">
|
277 |
<?php if($TwitterWidgetId) { ?>
|
278 |
-
<h2 class="well"
|
279 |
<hr>
|
280 |
<p>
|
281 |
<a class="twitter-timeline" data-dnt="true" href="https://twitter.com/<?php echo esc_attr($TwitterUserName); ?>"
|
@@ -346,17 +357,17 @@ if ( isset( $_REQUEST['wl_twitter_consumer_key'] ) && isset( $_REQUEST['twitter_
|
|
346 |
<input class="widefat wltt-slider" id="wl_twitter_tweets" name="wl_twitter_tweets" type="range" value="<?php if( isset( $wl_twitter_tweets ) ) {echo esc_attr($wl_twitter_tweets);} ?>" min="1" max="14" data-rangeSlider>
|
347 |
</p>
|
348 |
<p>
|
349 |
-
<b
|
350 |
</p>
|
351 |
<br>
|
352 |
<p>
|
353 |
<label><?php esc_html_e( 'Layout', 'twitter-tweets' ); ?></label>
|
354 |
<select class="widefat" name="wl_twitter_layout" id="wl_twitter_layout">
|
355 |
<option value=""><?php esc_html_e( 'Select', 'twitter-tweets' ); ?></option>
|
356 |
-
<option value="12"
|
357 |
-
<option value="6"
|
358 |
-
<option value="4"
|
359 |
-
<option value="3"
|
360 |
</select>
|
361 |
</p>
|
362 |
<script type="text/javascript">
|
@@ -375,7 +386,7 @@ if ( isset( $_REQUEST['wl_twitter_consumer_key'] ) && isset( $_REQUEST['twitter_
|
|
375 |
<div id="twitter-img" style="display: none;">
|
376 |
<img src="<?php echo WEBLIZAR_TWITTER_PLUGIN_URL.'images/loading.gif'; ?>" />
|
377 |
</div>
|
378 |
-
<div id="wl_twitter_preview" style="display: none;" class"alert">
|
379 |
<?php esc_html_e( 'Settings successfully saved. Reloading page for generating preview right side of setting.', 'twitter-tweets' ); ?>
|
380 |
</div>
|
381 |
</form>
|
@@ -517,7 +528,7 @@ if ( isset( $_REQUEST['wl_twitter_consumer_key'] ) && isset( $_REQUEST['twitter_
|
|
517 |
target="_blank"
|
518 |
onclick="window.open('https://twitter.com/intent/tweet?in_reply_to=<?php echo esc_attr($id_str); ?>&related=<?php echo esc_attr($screen_name); ?> retweet', 'newwindow', 'width=600,height=450'); return false;"><?php esc_html_e( 'Reply', 'twitter-tweets' ); ?>
|
519 |
</a>
|
520 |
-
</p>
|
521 |
<span class="wl-wtp-date-font-size"><?php if( isset( $status->created_at ) ) {echo tweet_time_calculate( $created_at );} ?>
|
522 |
<?php if( isset( $status->created_at ) ) {esc_html_e( 'ago', 'twitter-tweets' );} ?></span>
|
523 |
</div> <!-- Tweet box -->
|
79 |
|
80 |
if(isset($_REQUEST['twitter-page-user_name'])) {
|
81 |
|
82 |
+
if ( ! current_user_can( 'manage_options' ) || ! wp_verify_nonce( $_POST['feeds-widget'], 'save-feeds-widget' ) ) {
|
83 |
+
die;
|
84 |
+
}
|
85 |
+
|
86 |
+
$TwitterUserName = sanitize_text_field( $_REQUEST['twitter-page-user_name'] );
|
87 |
+
$Theme = sanitize_text_field( $_REQUEST['show-theme-background'] );
|
88 |
+
$Height = sanitize_text_field( $_REQUEST['twitter-page-url-Height'] );
|
89 |
+
$TwitterWidgetId = sanitize_text_field( $_REQUEST['twitter-page-id-fetch'] );
|
90 |
+
$LinkColor = sanitize_hex_color( $_REQUEST['twitter-page-lnk-Color'] );
|
91 |
+
$ExcludeReplies = sanitize_text_field ( $_REQUEST['exclude_replies_23'] );
|
92 |
+
$AutoExpandPhotos = sanitize_text_field ( $_REQUEST['photo_1234'] );
|
93 |
+
$tw_language = sanitize_text_field ( $_REQUEST['tw_language'] );
|
94 |
|
95 |
$TwitterSettingsArray = serialize(
|
96 |
array(
|
108 |
|
109 |
/* Twitter api key save */
|
110 |
|
111 |
+
if ( isset( $_REQUEST['wl_twitter_consumer_key'] ) && isset( $_REQUEST['twitter_api_nonce'] ) ) {
|
112 |
+
|
113 |
+
if ( ! current_user_can( 'manage_options' ) || ! wp_verify_nonce( $_POST['twitter_api_nonce'], 'twitter_api_nonce' ) ) {
|
114 |
+
die;
|
115 |
+
}
|
116 |
+
|
117 |
$wl_twitter_consumer_key = sanitize_text_field( $_REQUEST['wl_twitter_consumer_key'] );
|
118 |
$wl_twitter_consumer_secret = sanitize_text_field( $_REQUEST['wl_twitter_consumer_secret'] );
|
119 |
$wl_twitter_access_token = sanitize_text_field( $_REQUEST['wl_twitter_access_token'] );
|
179 |
if ( isset( $twitterSettings[ 'tw_language' ] ) ) {
|
180 |
$tw_language = $twitterSettings[ 'tw_language' ];
|
181 |
}
|
182 |
+
|
183 |
+
wp_nonce_field( 'save-feeds-widget', 'feeds-widget' );
|
184 |
?>
|
185 |
<p>
|
186 |
<label><?php esc_html_e( 'Twitter Account Username', 'twitter-tweets' ); ?></label>
|
203 |
<label><?php esc_html_e( 'Height', 'twitter-tweets' ); ?></label>
|
204 |
<input class="widefat wltt-slider" id="twitter-page-url-Height" name="twitter-page-url-Height" type="range" value="<?php echo esc_attr($Height ); ?>" min="0" max="1500" data-rangeSlider>
|
205 |
</p>
|
206 |
+
<p><b><?php esc_html_e( 'Set your desire height px', 'twitter-tweets' ); ?></b>: <span id="twitter-range-val"></span></p>
|
207 |
<br>
|
208 |
|
209 |
<p>
|
210 |
<label><?php esc_html_e( 'URL Link Color:', 'twitter-tweets' ); ?></label>
|
211 |
<input class="widefat wltt-color-field" id="twitter-page-lnk-Color" name="twitter-page-lnk-Color" type="text" value="<?php echo esc_attr( $LinkColor ); ?>" data-default-color="#effeff" >
|
212 |
|
213 |
+
<?php esc_html_e( 'Find More Color Codes', 'twitter-tweets' ); ?> <a href="http://html-color-codes.info/" target="_blank"><?php esc_html_e( 'HERE', 'twitter-tweets' ); ?></a>
|
214 |
</p>
|
215 |
<br>
|
216 |
|
217 |
<p>
|
218 |
<label><?php esc_html_e( 'Exclude Replies on Tweets', 'twitter-tweets' ); ?></label>
|
219 |
<select id="exclude_replies_23" name="exclude_replies_23">
|
220 |
+
<option value="yes" <?php if($ExcludeReplies == "yes") echo "selected=selected" ?>><?php esc_html_e( 'Yes', 'twitter-tweets' ); ?></option>
|
221 |
+
<option value="no" <?php if($ExcludeReplies == "no") echo "selected=selected" ?>><?php esc_html_e( 'No', 'twitter-tweets' ); ?></option>
|
222 |
</select>
|
223 |
</p>
|
224 |
<br>
|
225 |
<p>
|
226 |
<label><?php esc_html_e( 'Auto Expand Photos in Tweets', 'twitter-tweets' ); ?></label>
|
227 |
<select id="photo_1234" name="photo_1234">
|
228 |
+
<option value="yes" <?php if($AutoExpandPhotos == "yes") echo "selected=selected" ?>><?php esc_html_e( 'Yes', 'twitter-tweets' ); ?></option>
|
229 |
+
<option value="no" <?php if($AutoExpandPhotos == "no") echo "selected=selected" ?>><?php esc_html_e( 'No', 'twitter-tweets' ); ?></option>
|
230 |
</select>
|
231 |
</p>
|
232 |
<br>
|
277 |
<div id="fb-img" style="display: none;">
|
278 |
<img src="<?php echo WEBLIZAR_TWITTER_PLUGIN_URL.'images/loading.gif'; ?>" />
|
279 |
</div>
|
280 |
+
<div id="fb-msg" style="display: none;" class="alert">
|
281 |
<?php esc_html_e( 'Settings successfully saved. Reloading page for generating preview right side of setting.', 'twitter-tweets' ); ?>
|
282 |
</div>
|
283 |
</form>
|
286 |
<!-- Preview Part-->
|
287 |
<div class="col-md-6">
|
288 |
<?php if($TwitterWidgetId) { ?>
|
289 |
+
<h2 class="well"><?php esc_html_e( 'Feeds Shortcode Preview', 'twitter-tweets'); ?></h2>
|
290 |
<hr>
|
291 |
<p>
|
292 |
<a class="twitter-timeline" data-dnt="true" href="https://twitter.com/<?php echo esc_attr($TwitterUserName); ?>"
|
357 |
<input class="widefat wltt-slider" id="wl_twitter_tweets" name="wl_twitter_tweets" type="range" value="<?php if( isset( $wl_twitter_tweets ) ) {echo esc_attr($wl_twitter_tweets);} ?>" min="1" max="14" data-rangeSlider>
|
358 |
</p>
|
359 |
<p>
|
360 |
+
<b><?php esc_html_e( 'Set no of tweets you want to show', 'twitter-tweets' ); ?></b>: <span id="wl_twitter_range_show"></span>
|
361 |
</p>
|
362 |
<br>
|
363 |
<p>
|
364 |
<label><?php esc_html_e( 'Layout', 'twitter-tweets' ); ?></label>
|
365 |
<select class="widefat" name="wl_twitter_layout" id="wl_twitter_layout">
|
366 |
<option value=""><?php esc_html_e( 'Select', 'twitter-tweets' ); ?></option>
|
367 |
+
<option value="12"><?php esc_html_e( '1', 'twitter-tweets' ); ?></option>
|
368 |
+
<option value="6"><?php esc_html_e( '2', 'twitter-tweets' ); ?></option>
|
369 |
+
<option value="4"><?php esc_html_e( '3', 'twitter-tweets' ); ?></option>
|
370 |
+
<option value="3"><?php esc_html_e( '4', 'twitter-tweets' ); ?></option>
|
371 |
</select>
|
372 |
</p>
|
373 |
<script type="text/javascript">
|
386 |
<div id="twitter-img" style="display: none;">
|
387 |
<img src="<?php echo WEBLIZAR_TWITTER_PLUGIN_URL.'images/loading.gif'; ?>" />
|
388 |
</div>
|
389 |
+
<div id="wl_twitter_preview" style="display: none;" class="alert">
|
390 |
<?php esc_html_e( 'Settings successfully saved. Reloading page for generating preview right side of setting.', 'twitter-tweets' ); ?>
|
391 |
</div>
|
392 |
</form>
|
528 |
target="_blank"
|
529 |
onclick="window.open('https://twitter.com/intent/tweet?in_reply_to=<?php echo esc_attr($id_str); ?>&related=<?php echo esc_attr($screen_name); ?> retweet', 'newwindow', 'width=600,height=450'); return false;"><?php esc_html_e( 'Reply', 'twitter-tweets' ); ?>
|
530 |
</a>
|
531 |
+
</p>
|
532 |
<span class="wl-wtp-date-font-size"><?php if( isset( $status->created_at ) ) {echo tweet_time_calculate( $created_at );} ?>
|
533 |
<?php if( isset( $status->created_at ) ) {esc_html_e( 'ago', 'twitter-tweets' );} ?></span>
|
534 |
</div> <!-- Tweet box -->
|
twiiter_help_body.php
CHANGED
@@ -7,13 +7,13 @@
|
|
7 |
<div class="weblizar-submenu-links" id="weblizar-submenu-links">
|
8 |
<ul>
|
9 |
<li class=""><div class="dashicons dashicons-format-chat"></div>
|
10 |
-
<a href="https://wordpress.org/plugins/twitter-tweets/" target="_blank" title="Support Forum">
|
11 |
<?php esc_html_e('Support Forum', 'twitter-tweets');?></a>
|
12 |
</li>
|
13 |
<li class=""><div class="dashicons dashicons-welcome-write-blog"></div>
|
14 |
-
<a href="<?php echo WEBLIZAR_TWITTER_PLUGIN_URL.'readme.txt'; ?>" target="_blank" title="
|
15 |
<?php esc_html_e('Plugin Change Log','twitter-tweets');?></a>
|
16 |
-
</li>
|
17 |
</ul>
|
18 |
</div>
|
19 |
</div>
|
@@ -46,4 +46,4 @@
|
|
46 |
<?php require_once('twiiter_help.php'); ?>
|
47 |
</div>
|
48 |
</div>
|
49 |
-
</div>
|
7 |
<div class="weblizar-submenu-links" id="weblizar-submenu-links">
|
8 |
<ul>
|
9 |
<li class=""><div class="dashicons dashicons-format-chat"></div>
|
10 |
+
<a href="https://wordpress.org/plugins/twitter-tweets/" target="_blank" title="<?php esc_attr_e( 'Support Forum', 'twitter-tweets' ); ?>">
|
11 |
<?php esc_html_e('Support Forum', 'twitter-tweets');?></a>
|
12 |
</li>
|
13 |
<li class=""><div class="dashicons dashicons-welcome-write-blog"></div>
|
14 |
+
<a href="<?php echo WEBLIZAR_TWITTER_PLUGIN_URL.'readme.txt'; ?>" target="_blank" title="<?php esc_attr_e( 'Plugin Changelog', 'twitter-tweets' ); ?>">
|
15 |
<?php esc_html_e('Plugin Change Log','twitter-tweets');?></a>
|
16 |
+
</li>
|
17 |
</ul>
|
18 |
</div>
|
19 |
</div>
|
46 |
<?php require_once('twiiter_help.php'); ?>
|
47 |
</div>
|
48 |
</div>
|
49 |
+
</div>
|
twitter-tweets.php
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?php
|
2 |
/*
|
3 |
* Plugin Name: Customize Feeds for Twitter
|
4 |
-
* Version: 1.8.
|
5 |
* Description: Customize Feeds for Twitter plugin for WordPress. You can use this to display real time Twitter feeds on any where on your webiste by using shortcode or widgets
|
6 |
* Author: Weblizar
|
7 |
* Author URI: https://www.weblizar.com/
|
@@ -30,10 +30,9 @@ require_once("twitter-tweets_shortcode.php");
|
|
30 |
/**** Twitter widgets ***/
|
31 |
require_once("twitter_tweets_widgets.php");
|
32 |
|
33 |
-
|
34 |
/** Shortcode Settings Menu **/
|
35 |
function Weblizar_Twitter_Menu() {
|
36 |
-
$AdminMenu = add_menu_page( esc_html__('Customize Feeds for Twitter', 'twitter-tweets'), esc_html__('Customize Feeds for Twitter', 'twitter-tweets'), '
|
37 |
}
|
38 |
add_action('admin_menu','Weblizar_Twitter_Menu');
|
39 |
function Twitter_by_weblizar_page_function() {
|
@@ -70,5 +69,4 @@ function wl_twitter_settinglinks( $links ) {
|
|
70 |
}
|
71 |
$plugin_wl_twitter = plugin_basename( __FILE__ );
|
72 |
add_filter( "plugin_action_links_$plugin_wl_twitter", 'wl_twitter_settinglinks' );
|
73 |
-
|
74 |
?>
|
1 |
<?php
|
2 |
/*
|
3 |
* Plugin Name: Customize Feeds for Twitter
|
4 |
+
* Version: 1.8.9
|
5 |
* Description: Customize Feeds for Twitter plugin for WordPress. You can use this to display real time Twitter feeds on any where on your webiste by using shortcode or widgets
|
6 |
* Author: Weblizar
|
7 |
* Author URI: https://www.weblizar.com/
|
30 |
/**** Twitter widgets ***/
|
31 |
require_once("twitter_tweets_widgets.php");
|
32 |
|
|
|
33 |
/** Shortcode Settings Menu **/
|
34 |
function Weblizar_Twitter_Menu() {
|
35 |
+
$AdminMenu = add_menu_page( esc_html__('Customize Feeds for Twitter', 'twitter-tweets'), esc_html__('Customize Feeds for Twitter', 'twitter-tweets'), 'manage_options', 'Twitter', 'Twitter_by_weblizar_page_function', "dashicons-wordpress-alt");
|
36 |
}
|
37 |
add_action('admin_menu','Weblizar_Twitter_Menu');
|
38 |
function Twitter_by_weblizar_page_function() {
|
69 |
}
|
70 |
$plugin_wl_twitter = plugin_basename( __FILE__ );
|
71 |
add_filter( "plugin_action_links_$plugin_wl_twitter", 'wl_twitter_settinglinks' );
|
|
|
72 |
?>
|
twitter_tweets_widgets.php
CHANGED
@@ -14,15 +14,15 @@ class WeblizarTwitter extends WP_Widget {
|
|
14 |
$title = apply_filters('title', $instance['title']);
|
15 |
echo wp_kses_post($before_widget);
|
16 |
if (!empty($title)) { echo wp_kses_post($before_title . $title . $after_title); }
|
17 |
-
$TwitterUserName =
|
18 |
-
$Theme =
|
19 |
-
$Height =
|
20 |
-
$Width =
|
21 |
-
$LinkColor =
|
22 |
-
$ExcludeReplies =
|
23 |
-
$AutoExpandPhotos =
|
24 |
-
$TwitterWidgetId =
|
25 |
-
$tw_language =
|
26 |
?>
|
27 |
<div style="display:block;width:100%;float:left;overflow:hidden">
|
28 |
<a class="twitter-timeline" data-dnt="true" href="https://twitter.com/<?php echo esc_attr($TwitterUserName); ?>"
|
@@ -68,7 +68,7 @@ class WeblizarTwitter extends WP_Widget {
|
|
68 |
if ( isset( $instance[ 'LinkColor' ] ) ) {
|
69 |
$LinkColor = $instance[ 'LinkColor' ];
|
70 |
} else {
|
71 |
-
$LinkColor = "
|
72 |
}
|
73 |
|
74 |
if ( isset( $instance[ 'ExcludeReplies' ] ) ) {
|
@@ -196,8 +196,7 @@ class WeblizarTwitter extends WP_Widget {
|
|
196 |
$Theme = sanitize_text_field( 'theme', ( ! empty( $new_instance['Theme'] ) ) ? strip_tags( $new_instance['Theme'] ) : 'light' );
|
197 |
$Height = sanitize_text_field( ( ! empty( $new_instance['Height'] ) ) ? strip_tags( $new_instance['Height'] ) : '450' );
|
198 |
$Width = sanitize_text_field( ( ! empty( $new_instance['Width'] ) ) ? strip_tags( $new_instance['Width'] ) : '' );
|
199 |
-
|
200 |
-
$Linkcolor = sanitize_text_field( ( ! empty( $new_instance['LinkColor'] ) ) ? strip_tags( $new_instance['LinkColor'] ) : '#CC0000' );
|
201 |
$ExcludeReplies = sanitize_text_field( ( ! empty( $new_instance['ExcludeReplies'] ) ) ? strip_tags( $new_instance['ExcludeReplies'] ) : 'yes' );
|
202 |
$AutoExpandPhotos = sanitize_text_field( ( ! empty( $new_instance['AutoExpandPhotos'] ) ) ? strip_tags( $new_instance['AutoExpandPhotos'] ) : 'yes' );
|
203 |
$TwitterWidgetId = sanitize_text_field( ( ! empty( $new_instance['TwitterWidgetId'] ) ) ? strip_tags( $new_instance['TwitterWidgetId'] ) : '' );
|
@@ -221,4 +220,4 @@ class WeblizarTwitter extends WP_Widget {
|
|
221 |
function WeblizarTwitterWidget() {
|
222 |
register_widget( 'WeblizarTwitter' );
|
223 |
}
|
224 |
-
add_action( 'widgets_init', 'WeblizarTwitterWidget' );
|
14 |
$title = apply_filters('title', $instance['title']);
|
15 |
echo wp_kses_post($before_widget);
|
16 |
if (!empty($title)) { echo wp_kses_post($before_title . $title . $after_title); }
|
17 |
+
$TwitterUserName = $instance['TwitterUserName'];
|
18 |
+
$Theme = $instance['Theme'];
|
19 |
+
$Height = $instance['Height'];
|
20 |
+
$Width = $instance['Width'];
|
21 |
+
$LinkColor = $instance['LinkColor'];
|
22 |
+
$ExcludeReplies = $instance['ExcludeReplies'];
|
23 |
+
$AutoExpandPhotos = $instance['AutoExpandPhotos'];
|
24 |
+
$TwitterWidgetId = $instance['TwitterWidgetId'];
|
25 |
+
$tw_language = $instance['tw_language'];
|
26 |
?>
|
27 |
<div style="display:block;width:100%;float:left;overflow:hidden">
|
28 |
<a class="twitter-timeline" data-dnt="true" href="https://twitter.com/<?php echo esc_attr($TwitterUserName); ?>"
|
68 |
if ( isset( $instance[ 'LinkColor' ] ) ) {
|
69 |
$LinkColor = $instance[ 'LinkColor' ];
|
70 |
} else {
|
71 |
+
$LinkColor = "#0000ff";
|
72 |
}
|
73 |
|
74 |
if ( isset( $instance[ 'ExcludeReplies' ] ) ) {
|
196 |
$Theme = sanitize_text_field( 'theme', ( ! empty( $new_instance['Theme'] ) ) ? strip_tags( $new_instance['Theme'] ) : 'light' );
|
197 |
$Height = sanitize_text_field( ( ! empty( $new_instance['Height'] ) ) ? strip_tags( $new_instance['Height'] ) : '450' );
|
198 |
$Width = sanitize_text_field( ( ! empty( $new_instance['Width'] ) ) ? strip_tags( $new_instance['Width'] ) : '' );
|
199 |
+
$Linkcolor = sanitize_hex_color( ( ! empty( $new_instance['LinkColor'] ) ) ? strip_tags( $new_instance['LinkColor'] ) : '#CC0000' );
|
|
|
200 |
$ExcludeReplies = sanitize_text_field( ( ! empty( $new_instance['ExcludeReplies'] ) ) ? strip_tags( $new_instance['ExcludeReplies'] ) : 'yes' );
|
201 |
$AutoExpandPhotos = sanitize_text_field( ( ! empty( $new_instance['AutoExpandPhotos'] ) ) ? strip_tags( $new_instance['AutoExpandPhotos'] ) : 'yes' );
|
202 |
$TwitterWidgetId = sanitize_text_field( ( ! empty( $new_instance['TwitterWidgetId'] ) ) ? strip_tags( $new_instance['TwitterWidgetId'] ) : '' );
|
220 |
function WeblizarTwitterWidget() {
|
221 |
register_widget( 'WeblizarTwitter' );
|
222 |
}
|
223 |
+
add_action( 'widgets_init', 'WeblizarTwitterWidget' );
|