Custom Twitter Feeds - Version 1.0.1

Version Description

  • Bug fixes
Download this release

Release Info

Developer smashballoon
Plugin Icon 128x128 Custom Twitter Feeds
Version 1.0.1
Comparing to
See all releases

Code changes from version 1.0 to 1.0.1

README.txt CHANGED
@@ -1,11 +1,11 @@
1
  === Custom Twitter Feeds ===
2
  Author: Smash Balloon
3
  Contributors: smashballoon, craig-at-smash-balloon
4
- Support Website: http://smashballoon.com/custom-twitter-feed/
5
- Tags: Twitter, Twitter feed, Custom Twitter Feed
6
  Requires at least: 3.0
7
- Tested up to: 4.5
8
- Stable tag: 1.0
9
  License: GPLv2 or later
10
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
11
 
@@ -21,43 +21,121 @@ Display **completely customizable**, **responsive** and **search engine crawlabl
21
  * Display multiple feeds from different Twitter users on multiple pages or widgets
22
  * Post caching means that your feed loads lightning fast and minimizes Twitter API requests
23
  * **Infinitely load more** of your Tweets with the 'Load More' button
 
24
  * Fully internationalized and translatable into any language
25
  * Display a beautiful header at the top of your feed
26
  * Enter your own custom CSS for even deeper customization
27
 
28
- For simple step-by-step directions on how to set up the Custom Twitter Feeds plugin please refer to our [setup guide](http://smashballoon.com/custom-twitter-feed/free/ 'Custom Twitter Feed setup guide').
29
 
30
  = Feedback or Support =
31
- We're dedicated to providing the most customizable, robust and well supported Twitter feed plugin in the world, so if you have an issue or any feedback on how to improve the plugin then please [let us know](https://smashballoon.com/custom-twitter-feed/support/ 'Twitter Feed Support').
32
 
33
- If you like the plugin then please consider leaving a review, as it really helps to support the plugin. If you have an issue then please allow us to help you fix it before leaving a review. Just [let us know](https://smashballoon.com/custom-twitter-feed/support/ 'Twitter Feed Support') what the problem is and we'll get back to you right away.
34
 
35
- We're currently working on a [Pro version](http://smashballoon.com/custom-twitter-feed/ 'Custom Twitter Feed Pro') which includes some awesome additional features! Sign up to be notified when it's released.
36
 
37
  == Installation ==
38
  1. Install the Custom Twitter Feeds plugin either via the WordPress plugin directory, or by uploading the files to your web server (in the /wp-content/plugins/ directory).
39
  2. Activate the plugin through the 'Plugins' menu in WordPress.
40
  3. Navigate to the 'Twitter Feed' settings page to configure your feed.
41
- 4. Use the shortcode [custom-twitter-feed] in your page, post or widget to display your feed.
42
- 5. You can display multiple feeds with different configurations by specifying the necessary parameters directly in the shortcode: [custom-twitter-feed hashtag=#smashballoon].
43
 
44
- For simple step-by-step directions on how to set up the Custom Twitter Feed plugin please refer to our [setup guide](http://smashballoon.com/custom-twitter-feed/free/ 'Custom Twitter Feed setup guide').
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
45
 
46
  == Frequently Asked Questions ==
47
 
48
  = Can I display multiple Twitter feeds on my site or on the same page? =
49
 
50
- Yep. You can display multiple Twitter feeds by using our built-in shortcode options, for example: `[custom-twitter-feed screenname="smashballoon" num=3]`.
51
 
52
  = How do I embed the Twitter Feed directly into a WordPress page template? =
53
 
54
- You can embed your Twitter feed directly into a template file by using the WordPress [do_shortcode](http://codex.wordpress.org/Function_Reference/do_shortcode) function: `<?php echo do_shortcode('[custom-twitter-feed]'); ?>`.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
55
 
56
  == Screenshots ==
57
 
58
- 1. Default plugin styling
59
- 2. The Custom Twitter Feed plugin Settings pages
60
 
61
  == Changelog ==
 
 
 
62
  = 1.0 =
63
- * Launch!
1
  === Custom Twitter Feeds ===
2
  Author: Smash Balloon
3
  Contributors: smashballoon, craig-at-smash-balloon
4
+ Support Website: http://smashballoon/custom-twitter-feeds/
5
+ Tags: Twitter, Twitter feed, Custom Twitter Feed, Twitter feeds, Custom Twitter Feeds, Tweets, Custom Tweets, Tweets feed, Twitter widget, Custom Twitter widget, Twitter plugin, Twitter API, Twitter tweets
6
  Requires at least: 3.0
7
+ Tested up to: 4.5.2
8
+ Stable tag: 1.0.1
9
  License: GPLv2 or later
10
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
11
 
21
  * Display multiple feeds from different Twitter users on multiple pages or widgets
22
  * Post caching means that your feed loads lightning fast and minimizes Twitter API requests
23
  * **Infinitely load more** of your Tweets with the 'Load More' button
24
+ * Built-in easy to use "Custom Twitter Feeds" Widget
25
  * Fully internationalized and translatable into any language
26
  * Display a beautiful header at the top of your feed
27
  * Enter your own custom CSS for even deeper customization
28
 
29
+ For simple step-by-step directions on how to set up the Custom Twitter Feeds plugin please refer to our [setup guide](http://smashballoon.com/custom-twitter-feeds/free/ 'Custom Twitter Feeds setup guide').
30
 
31
  = Feedback or Support =
32
+ We're dedicated to providing the most customizable, robust and well supported Twitter feed plugin in the world, so if you have an issue or any feedback on how to improve the plugin then please [let us know](https://smashballoon.com/custom-twitter-feeds/support/ 'Twitter Feed Support').
33
 
34
+ If you like the plugin then please consider leaving a review, as it really helps to support the plugin. If you have an issue then please allow us to help you fix it before leaving a review. Just [let us know](https://smashballoon.com/custom-twitter-feeds/support/ 'Twitter Feed Support') what the problem is and we'll get back to you right away.
35
 
36
+ We're currently working on a [Pro version](http://smashballoon.com/custom-twitter-feeds/ 'Custom Twitter Feeds Pro') which includes some awesome additional features! Sign up to be notified when it's released.
37
 
38
  == Installation ==
39
  1. Install the Custom Twitter Feeds plugin either via the WordPress plugin directory, or by uploading the files to your web server (in the /wp-content/plugins/ directory).
40
  2. Activate the plugin through the 'Plugins' menu in WordPress.
41
  3. Navigate to the 'Twitter Feed' settings page to configure your feed.
42
+ 4. Use the shortcode [custom-twitter-feeds] in your page, post or widget to display your feed.
43
+ 5. You can display multiple feeds with different configurations by specifying the necessary parameters directly in the shortcode: [custom-twitter-feeds hashtag=#smashballoon].
44
 
45
+ For simple step-by-step directions on how to set up Custom Twitter Feeds plugin please refer to our [setup guide](http://smashballoon.com/custom-twitter-feeds/free/ 'Custom Twitter Feeds setup guide').
46
+
47
+ = Setting up the Free Custom Twitter Feeds WordPress Plugin =
48
+
49
+ The Custom Twitter Feeds plugin is brand new and so we're currently working on improving our documentation for it. If you have an issue or question please submit a support ticket and we'll get back to you as soon as we can.
50
+
51
+ 1) Once you've installed the plugin click on the Twitter Feed item in your WordPress menu
52
+
53
+ 2) Click on the large blue Twitter login button to get your Twitter Access Token and Twitter Secret. Note; if you have your own Twitter Developer App set up then you can enter your Twitter information manually by enabling the checkbox below the Twitter login button.
54
+
55
+ 3) Authorize the plugin to read your Tweets.
56
+ Note; the plugin does not obtain permission to edit or write to your Twitter account, only to read your Twitter content.
57
+
58
+ 4) Twitter sends back your Twitter Access Token and Twitter Secret which are then automatically saved by the Custom Twitter Feeds plugin. This information is required in order to connect to the Twitter API.
59
+
60
+ 5) Enter a Twitter screenname to display Tweets from. Alternatively, choose to display Tweets from your Twitter home timeline or a Twitter hashtag.
61
+
62
+ 6) Navigate to the Customize and Style pages to customize your Twitter feed.
63
+
64
+ 7) Once you've customized your Twitter feed, click on the "Display Your Feed" tab for directions on how to display your Twitter feed (or multiple feeds).
65
+
66
+ 8) Copy the [custom-twitter-feeds] shortcode and paste it into any page, post or widget where you want the Twitter feed to appear.
67
+
68
+ 9) You can paste the [custom-twitter-feeds] shortcode directly into your page editor.
69
+
70
+ 10) You can use the default WordPress 'Text' widget to display your Twitter Feed in a sidebar or other widget area.
71
+
72
+ 11) View your website to see your Twitter feed(s) in all their glory!
73
 
74
  == Frequently Asked Questions ==
75
 
76
  = Can I display multiple Twitter feeds on my site or on the same page? =
77
 
78
+ Yep. You can display multiple Twitter feeds by using our built-in shortcode options, for example: `[custom-twitter-feeds screenname="smashballoon" num=3]`.
79
 
80
  = How do I embed the Twitter Feed directly into a WordPress page template? =
81
 
82
+ You can embed your Twitter feed directly into a template file by using the WordPress [do_shortcode](http://codex.wordpress.org/Function_Reference/do_shortcode) function: `<?php echo do_shortcode('[custom-twitter-feeds]'); ?>`.
83
+
84
+ == Other Notes ==
85
+
86
+ = Twitter API Error Message Reference =
87
+
88
+ If you receive an error message when trying to display your Twitter Feed then you can use the error reference below to diagnose the issue and find the relevant solution.
89
+
90
+ **Error:**
91
+ Could not authenticate you
92
+
93
+ **Causes:**
94
+ - You may be using Twitter access tokens that are not valid - See #1 below
95
+ - You checked the box to enter your own Twitter app information, but one or more of the fields are incorrect - See #2 below
96
+
97
+ **Error:**
98
+ Invalid or expired token
99
+
100
+ **Causes:**
101
+ - You may not have entered your Twitter access tokens or they are not valid - See #1 below
102
+
103
+ **Error:**
104
+ Unable to load tweets (with no other explanation)
105
+
106
+ **Causes:**
107
+ - You may need to raise the number of tweets to retrieve and display in your Twitter feed - See #3 below
108
+
109
+ **Error:**
110
+ Sorry, that page does not exist
111
+
112
+ **Causes:**
113
+ - There may be a typo in the Twitter screen name or hashtag you are attempting to use
114
+
115
+ **Solutions**
116
+
117
+ **#1 - Your Twitter access tokens might not be valid**
118
+
119
+ The easiest way to verify this is by going back to the Settings page for the Custom Twitter Feeds plugin and clicking the big blue button on the "Configure" tab to get new Twitter access tokens. If you haven't set up your own Twitter App, the only way to use the Custom Twitter Feeds plugin is to click the big blue button to get a Twitter access token and Twitter access token secret that is compatible with the default Twitter client used by Smash Balloon.
120
+
121
+ **#2 - You have checked the box to use your own Twitter app information but one or more of the fields are incorrect**
122
+
123
+ All four fields, consumer token, consumer secret, access token, and access token secret, need to come from the Twitter app that you set up on Twitter.com. Try returning to your personal Twitter app management page https://apps.twitter.com/ and confirming that all four fields, consumer token, consumer secret, access token, and access token secret, and entered correctly in the corresponding fields on the plugin's "Configure" tab.
124
+
125
+ **#3 - You may need to raise the number of tweets to retrieve**
126
+
127
+ Navigate to the type of Twitter feed you are trying to display on twitter.com. For example, if you are displaying a feed from the screenname "smashballoon", go to https://twitter.com/smashballoon. Make sure there are tweets visible. Then click on the link "Tweets & replies". If there are a more recent replies than original tweets, there may be too many tweets being filtered out to display any. Replies are removed by default. You can raise the number of tweets to retrieve initially by going to the Custom Twitter Feed Settings page, "Customize" tab, and navigating to the "Advanced" area. Then raise the "Tweet Multiplier" and test to see if your Twitter feed now displays tweets.
128
+
129
+ If you're still having trouble displaying your Tweets after trying the common issues above then please [contact support](https://smashballoon.com/custom-twitter-feeds/support/) for assistance.
130
 
131
  == Screenshots ==
132
 
133
+ 1. Default Custom Twitter Feeds plugin styling
134
+ 2. Custom Twitter Feeds plugin Settings pages
135
 
136
  == Changelog ==
137
+ = 1.0.1 =
138
+ * Bug fixes
139
+
140
  = 1.0 =
141
+ * Launched the Custom Twitter Feeds plugin!
css/ctf-admin-styles.css CHANGED
@@ -133,6 +133,11 @@
133
  clear: both;
134
  margin: 10px 0 10px 0;
135
  }
 
 
 
 
 
136
  #ctf_config_info{
137
  float: left;
138
  clear: both;
@@ -310,7 +315,7 @@
310
  #ctf-admin .ctf-success{
311
  font-size: 14px;
312
  }
313
- #toplevel_page_custom-twitter-feed .dashicons-admin-generic:before {
314
  content: "\f301";
315
  }
316
 
133
  clear: both;
134
  margin: 10px 0 10px 0;
135
  }
136
+ #ctf_config .ctf-tooltip-link{
137
+ position: relative;
138
+ top: 13px;
139
+ left: 6px;
140
+ }
141
  #ctf_config_info{
142
  float: left;
143
  clear: both;
315
  #ctf-admin .ctf-success{
316
  font-size: 14px;
317
  }
318
+ #toplevel_page_custom-twitter-feeds .dashicons-admin-generic:before {
319
  content: "\f301";
320
  }
321
 
css/ctf-styles.css CHANGED
@@ -90,6 +90,9 @@
90
  width: 100%;
91
  padding-top: 5px;
92
  }
 
 
 
93
  #ctf .ctf-header a{
94
  text-decoration: none;
95
  }
@@ -258,6 +261,9 @@
258
  color: #77c7f7;
259
  margin-left: 0;
260
  }
 
 
 
261
  #ctf .ctf-tweet-meta{
262
  display: inline-block;
263
  }
@@ -296,7 +302,7 @@
296
  /*Quoted tweets*/
297
  #ctf .ctf-quoted-tweet{
298
  display: block;
299
- float: left;
300
  clear: both;
301
  margin: 7px 0 5px 58px;
302
  padding: 8px 12px;
@@ -487,7 +493,7 @@
487
  #ctf .ctf-error iframe,
488
  #ctf .ctf-error code{
489
  padding: 0;
490
- margin: 0;
491
  }
492
  #ctf .ctf-error-user p{
493
  padding-bottom: 5px;
@@ -527,7 +533,7 @@
527
  }
528
  #ctf .ctf-out-of-tweets p,
529
  #ctf .ctf-out-of-tweets iframe{
530
- margin: 0;
531
  padding: 0;
532
  }
533
  #ctf .ctf-out-of-tweets p{
90
  width: 100%;
91
  padding-top: 5px;
92
  }
93
+ #ctf .ctf-no-bio .ctf-header-text{
94
+ padding-top: 13px;
95
+ }
96
  #ctf .ctf-header a{
97
  text-decoration: none;
98
  }
261
  color: #77c7f7;
262
  margin-left: 0;
263
  }
264
+ #ctf .ctf-quoted-verified {
265
+ margin-right: 4px;
266
+ }
267
  #ctf .ctf-tweet-meta{
268
  display: inline-block;
269
  }
302
  /*Quoted tweets*/
303
  #ctf .ctf-quoted-tweet{
304
  display: block;
305
+ /*float: left;*/
306
  clear: both;
307
  margin: 7px 0 5px 58px;
308
  padding: 8px 12px;
493
  #ctf .ctf-error iframe,
494
  #ctf .ctf-error code{
495
  padding: 0;
496
+ margin: 0 2px;
497
  }
498
  #ctf .ctf-error-user p{
499
  padding-bottom: 5px;
533
  }
534
  #ctf .ctf-out-of-tweets p,
535
  #ctf .ctf-out-of-tweets iframe{
536
+ margin: 0 2px;
537
  padding: 0;
538
  }
539
  #ctf .ctf-out-of-tweets p{
custom-twitter-feed.php CHANGED
@@ -1,12 +1,12 @@
1
  <?php
2
  /*
3
- Plugin Name: Custom Twitter Feed
4
- Plugin URI: http://smashballoon.com/custom-twitter-feed
5
- Description: A customizable Twitter feed for your website
6
- Version: 1.0
7
  Author: Smash Balloon
8
  Author URI: http://smashballoon.com/
9
- Text Domain: custom-twitter-feed
10
  */
11
  /*
12
  Copyright 2016 Smash Balloon LLC (email : hey@smashballoon.com)
@@ -24,9 +24,9 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
24
  */
25
 
26
  define( 'CTF_URL', plugin_dir_path( __FILE__ ) );
27
- define( 'CTFVER', '1.0' );
28
- define( 'CTF_TITLE', 'Custom Twitter Feed' );
29
- define( 'CTF_JS_URL', plugins_url( '/js/ctf-scripts.js?ver=' . CTFVER , __FILE__ ) );
30
  define( 'OAUTH_PROCESSOR_URL', 'https://smashballoon.com/ctf-at-retriever/?return_uri=' );
31
 
32
  require_once( CTF_URL . '/inc/widget.php' );
@@ -64,6 +64,7 @@ function ctf_init( $atts ) {
64
  }
65
  }
66
  add_shortcode( 'custom-twitter-feed', 'ctf_init' );
 
67
 
68
  /**
69
  * Called via ajax to get more posts after the "load more" button is clicked
@@ -242,9 +243,9 @@ register_deactivation_hook( __FILE__, 'ctf_deactivate' );
242
  * Loads the javascript for the plugin front-end. Also localizes the admin-ajax file location for use in ajax calls
243
  */
244
  function ctf_scripts_and_styles() {
245
- wp_enqueue_style( 'ctf_styles', plugins_url( '/css/ctf-styles.css?ver=' . CTFVER, __FILE__ ) );
246
  wp_enqueue_script( 'ctf_twitter_intents', 'https://platform.twitter.com/widgets.js' );
247
- wp_enqueue_script( 'ctf_scripts', plugins_url( '/js/ctf-scripts.js?ver=' . CTFVER, __FILE__ ), array( 'jquery' ), '', true );
248
  wp_localize_script( 'ctf_scripts', 'ctf', array(
249
  'ajax_url' => admin_url( 'admin-ajax.php' )
250
  )
@@ -261,7 +262,7 @@ function ctf_custom_js() {
261
 
262
  if ( ! empty( $ctf_custom_js ) ) {
263
  ?>
264
- <!-- Custom Twitter Feed JS -->
265
  <script type="text/javascript">
266
  jQuery(document).ready(function($) {
267
  <?php echo stripslashes( $ctf_custom_js ) . "\r\n"; ?>
@@ -281,7 +282,7 @@ function ctf_custom_css() {
281
 
282
  if ( ! empty( $ctf_custom_css ) ) {
283
  ?>
284
- <!-- Custom Twitter Feed CSS -->
285
  <style type="text/css">
286
  <?php echo stripslashes( $ctf_custom_css ) . "\r\n"; ?>
287
  </style>
@@ -294,8 +295,8 @@ add_action( 'wp_head', 'ctf_custom_css' );
294
  * Some CSS and JS needed in the admin area as well
295
  */
296
  function ctf_admin_scripts_and_styles() {
297
- wp_enqueue_style( 'ctf_admin_styles', plugins_url( '/css/ctf-admin-styles.css?ver=' . CTFVER, __FILE__ ) );
298
- wp_enqueue_script( 'ctf_admin_scripts', plugins_url( '/js/ctf-admin-scripts.js?ver=' . CTFVER, __FILE__ ) , array( 'jquery' ), '', false );
299
  wp_localize_script( 'ctf_admin_scripts', 'ctf', array(
300
  'ajax_url' => admin_url( 'admin-ajax.php' ),
301
  'sb_nonce' => wp_create_nonce( 'ctf-smash-balloon' )
1
  <?php
2
  /*
3
+ Plugin Name: Custom Twitter Feeds
4
+ Plugin URI: http://smashballoon.com/custom-twitter-feeds
5
+ Description: Customizable Twitter feeds for your website
6
+ Version: 1.0.1
7
  Author: Smash Balloon
8
  Author URI: http://smashballoon.com/
9
+ Text Domain: custom-twitter-feeds
10
  */
11
  /*
12
  Copyright 2016 Smash Balloon LLC (email : hey@smashballoon.com)
24
  */
25
 
26
  define( 'CTF_URL', plugin_dir_path( __FILE__ ) );
27
+ define( 'CTF_VERSION', '1.0.1' );
28
+ define( 'CTF_TITLE', 'Custom Twitter Feeds' );
29
+ define( 'CTF_JS_URL', plugins_url( '/js/ctf-scripts.js?ver=' . CTF_VERSION , __FILE__ ) );
30
  define( 'OAUTH_PROCESSOR_URL', 'https://smashballoon.com/ctf-at-retriever/?return_uri=' );
31
 
32
  require_once( CTF_URL . '/inc/widget.php' );
64
  }
65
  }
66
  add_shortcode( 'custom-twitter-feed', 'ctf_init' );
67
+ add_shortcode( 'custom-twitter-feeds', 'ctf_init' );
68
 
69
  /**
70
  * Called via ajax to get more posts after the "load more" button is clicked
243
  * Loads the javascript for the plugin front-end. Also localizes the admin-ajax file location for use in ajax calls
244
  */
245
  function ctf_scripts_and_styles() {
246
+ wp_enqueue_style( 'ctf_styles', plugins_url( '/css/ctf-styles.css', __FILE__ ), array(), CTF_VERSION );
247
  wp_enqueue_script( 'ctf_twitter_intents', 'https://platform.twitter.com/widgets.js' );
248
+ wp_enqueue_script( 'ctf_scripts', plugins_url( '/js/ctf-scripts.js', __FILE__ ), array( 'jquery' ), CTF_VERSION, true );
249
  wp_localize_script( 'ctf_scripts', 'ctf', array(
250
  'ajax_url' => admin_url( 'admin-ajax.php' )
251
  )
262
 
263
  if ( ! empty( $ctf_custom_js ) ) {
264
  ?>
265
+ <!-- Custom Twitter Feeds JS -->
266
  <script type="text/javascript">
267
  jQuery(document).ready(function($) {
268
  <?php echo stripslashes( $ctf_custom_js ) . "\r\n"; ?>
282
 
283
  if ( ! empty( $ctf_custom_css ) ) {
284
  ?>
285
+ <!-- Custom Twitter Feeds CSS -->
286
  <style type="text/css">
287
  <?php echo stripslashes( $ctf_custom_css ) . "\r\n"; ?>
288
  </style>
295
  * Some CSS and JS needed in the admin area as well
296
  */
297
  function ctf_admin_scripts_and_styles() {
298
+ wp_enqueue_style( 'ctf_admin_styles', plugins_url( '/css/ctf-admin-styles.css', __FILE__ ), array(), CTF_VERSION );
299
+ wp_enqueue_script( 'ctf_admin_scripts', plugins_url( '/js/ctf-admin-scripts.js', __FILE__ ) , array( 'jquery' ), CTF_VERSION, false );
300
  wp_localize_script( 'ctf_admin_scripts', 'ctf', array(
301
  'ajax_url' => admin_url( 'admin-ajax.php' ),
302
  'sb_nonce' => wp_create_nonce( 'ctf-smash-balloon' )
img/pro-notice.png CHANGED
Binary file
inc/CtfAdmin.php CHANGED
@@ -21,10 +21,10 @@ class CtfAdmin
21
  public function add_menu()
22
  {
23
  add_menu_page(
24
- 'Twitter Feed',
25
- 'Twitter Feed',
26
  'manage_options',
27
- 'custom-twitter-feed',
28
  array( $this, 'create_options_page' ),
29
  '',
30
  99
@@ -66,8 +66,8 @@ class CtfAdmin
66
  <input name="<?php echo 'ctf_configure'.'[have_own_tokens]'; ?>" id="ctf_have_own_tokens" type="checkbox" <?php if ( $option_checked ) echo "checked"; ?> />
67
  <label for="ctf_have_own_tokens" class="ctf_checkbox"><?php _e( 'Or, manually enter my own Twitter app information' ); ?></label>
68
  <span class="ctf-tooltip-wrap">
69
- <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feed' ); ?></a>
70
- <p class="ctf-tooltip ctf-more-info"><?php _e( 'Check this box if you would like to manually enter the information from your own <a href="https://apps.twitter.com/" target="_blank">Twitter app</a>', 'custom-twitter-feed' ); ?>.</p>
71
  </span>
72
  <?php
73
  }
@@ -83,20 +83,24 @@ class CtfAdmin
83
  <div id="ctf_config">
84
 
85
  <?php if ( isset( $access_token_data['oauth_token'] ) ) : ?>
86
- <a href="<?php echo OAUTH_PROCESSOR_URL . admin_url( 'admin.php?page=custom-twitter-feed' ); ?>" id="ctf-get-token"><i class="fa fa-twitter"></i><?php _e( 'Log in to Twitter and get my Access Token and Secret' ); ?></a>
 
 
87
  <input type="hidden" id="ctf-retrieved-access-token" value="<?php echo esc_html( sanitize_text_field( $access_token_data['oauth_token'] ) ); ?>">
88
  <input type="hidden" id="ctf-retrieved-access-token-secret" value="<?php echo esc_html( sanitize_text_field( $access_token_data['oauth_token_secret'] ) ); ?>">
89
  <input type="hidden" id="ctf-retrieved-default-screen-name" value="<?php echo esc_html( sanitize_text_field( $access_token_data['screen_name'] ) ); ?>">
90
 
91
  <?php elseif ( isset( $access_token_data['error'] ) && ! isset( $access_token_data['oauth_token'] ) ) : ?>
92
 
93
- <p class="ctf_notice"><?php _e( 'There was an error with retrieving your access tokens. Please <a href="https://smashballoon.com/custom-twitter-feed/support/" target="_blank">contact support</a> for assistance.' ); ?></p>
94
- <a href="<?php echo OAUTH_PROCESSOR_URL . admin_url( 'admin.php?page=custom-twitter-feed' ); ?>" id="ctf-get-token"><i class="fa fa-twitter"></i><?php _e( 'Log in to Twitter and get my Access Token and Secret' ); ?></a>
 
95
 
96
  <?php else : ?>
97
 
98
- <a href="<?php echo OAUTH_PROCESSOR_URL . admin_url( 'admin.php?page=custom-twitter-feed' ); ?>" id="ctf-get-token"><i class="fa fa-twitter"></i><?php _e( 'Log in to Twitter and get my Access Token and Secret' ); ?></a>
99
-
 
100
  <?php endif; ?>
101
 
102
  </div>
@@ -131,7 +135,7 @@ class CtfAdmin
131
  'section' => 'ctf_configure_connect', // matches the section name
132
  'option' => 'ctf_configure', // matches the options name
133
  'class' => 'ctf-toggle-consumer', // class for the wrapper and input field
134
- 'whatis' => "A Consumer Key and a Consumer Secret are both needed for this plugin to work. You can find these here (insert link)", // what is this? text
135
  'size' => '27'
136
  ) );
137
 
@@ -144,7 +148,7 @@ class CtfAdmin
144
  'section' => 'ctf_configure_connect', // matches the section name
145
  'option' => 'ctf_configure', // matches the options name
146
  'class' => 'ctf-toggle-consumer', // class for the wrapper and input field
147
- 'whatis' => "A Consumer Key and a Consumer Secret are both needed for this plugin to work. You can find these here (insert link)", // what is this? text
148
  'size' => '57'
149
  ) );
150
 
@@ -433,14 +437,14 @@ class CtfAdmin
433
  // credit ctf
434
  $this->create_settings_field( array(
435
  'name' => 'creditctf',
436
- 'title' => '<label for="ctf_creditctf">Add Custom Twitter Feed Credit</label><code class="ctf_shortcode">creditctf
437
  Eg: creditctf=true</code>', // label for the input field
438
  'callback' => 'default_checkbox', // name of the function that outputs the html
439
  'page' => 'ctf_customize_showandhide', // matches the section name
440
  'section' => 'ctf_customize_showandhide', // matches the section name
441
  'option' => 'ctf_customize', // matches the options name
442
  'class' => '',
443
- 'whatis' => "Help us keep this plugin great! Add a link below your feed to credit Custom Twitter Feed by Smash Balloon"
444
  ));
445
 
446
  add_settings_section(
@@ -718,7 +722,7 @@ class CtfAdmin
718
  // header text color
719
  $this->create_settings_field( array(
720
  'name' => 'headertextcolor',
721
- 'title' => '<label for="ctf_headertextcolor">Tweet Background Color</label><code class="ctf_shortcode">headertextcolor
722
  Eg: headertextcolor=#444</code>', // label for the input field
723
  'callback' => 'default_color', // name of the function that outputs the html
724
  'page' => 'ctf_style_header', // matches the section name
@@ -953,8 +957,8 @@ class CtfAdmin
953
  <span><?php echo $args['example']; ?></span>
954
  <?php endif; ?>
955
  <?php if ( isset( $args['whatis'] ) ) : ?>
956
- <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feed' ); ?></a>
957
- <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feed' ); ?>.</p>
958
  <?php endif; ?>
959
  <?php
960
  }
@@ -966,12 +970,12 @@ class CtfAdmin
966
  ?>
967
  <select name="<?php echo $args['option'].'['.$args['name'].']'; ?>" id="ctf_<?php echo $args['name']; ?>" class="<?php echo $args['class']; ?>">
968
  <?php foreach ( $args['fields'] as $field ) : ?>
969
- <option value="<?php echo $field[0]; ?>" id="ctf-<?php echo $args['name']; ?>" class="<?php echo $args['class']; ?>"<?php if( $selected == $field[0] ) { echo ' selected'; } ?>><?php _e( $field[1], 'custom-twitter-feed' ); ?></option>
970
  <?php endforeach; ?>
971
  </select>
972
  <?php if ( isset( $args['whatis'] ) ) : ?>
973
- <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feed' ); ?></a>
974
- <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feed' ); ?>.</p>
975
  <?php endif; ?>
976
  <?php
977
  }
@@ -992,8 +996,8 @@ class CtfAdmin
992
  ?>
993
  <input name="<?php echo $args['option'].'['.$args['name'].']'; ?>" id="ctf_<?php echo $args['name']; ?>" type="checkbox" <?php if ( $option_checked ) echo "checked"; ?> />
994
  <?php if ( isset( $args['whatis'] ) ) : ?>
995
- <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feed' ); ?></a>
996
- <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feed' ); ?>.</p>
997
  <?php endif; ?>
998
  <?php
999
  }
@@ -1005,8 +1009,8 @@ class CtfAdmin
1005
  ?>
1006
  <input name="<?php echo $args['option'].'['.$args['name'].']'; ?>" id="ctf_<?php echo $args['name']; ?>" type="checkbox" <?php if ( $option_checked ) echo "checked"; ?> />
1007
  <?php if ( isset( $args['whatis'] ) ) : ?>
1008
- <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feed' ); ?></a>
1009
- <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feed' ); ?>.</p>
1010
  <?php endif; ?>
1011
  <?php
1012
  }
@@ -1029,8 +1033,8 @@ class CtfAdmin
1029
  <?php endif; ?>
1030
 
1031
  <?php if ( isset( $args['whatis'] ) ) : ?>
1032
- <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feed' ); ?></a>
1033
- <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feed' ); ?>.</p>
1034
  <?php endif; ?>
1035
 
1036
  <?php
@@ -1044,18 +1048,18 @@ class CtfAdmin
1044
  $option_string = ( isset( $options[ $args['name'].'_text' ] ) ) ? esc_attr( $options[ $args['name'].'_text' ] ) : '';
1045
  ?>
1046
  <input type="radio" name="<?php echo $args['option'].'[type]'; ?>" class="ctf-feed-settings-radio" id="ctf_<?php echo $args['name'].'_radio'; ?>" value="<?php echo $args['name']; ?>" <?php if ( $option_checked ) echo "checked"; ?> />
1047
- <label class="ctf-radio-label" for="ctf_<?php echo $args['name'].'_radio'; ?>"><?php _e( $args['label'], 'custom-twitter-feed' ); ?></label>
1048
  <?php if ( $args['has_input'] ) : ?>
1049
  <input name="<?php echo $args['option'].'['.$args['name'].'_text'.']'; ?>" id="ctf_<?php echo $args['name'].'_text'; ?>" type="text" value="<?php esc_attr_e( $option_string ); ?>" size="25" />
1050
  <?php endif; ?>
1051
  <?php if ( isset( $args['whatis'] ) ) : ?>
1052
- <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feed' ); ?></a>
1053
- <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feed' ); ?>.</p>
1054
  <?php endif; ?>
1055
  <?php if ( $args['has_replies'] ) : ?>
1056
  <span class="ctf_include_replies_toggle ctf_pro">
1057
  <input name="<?php echo $args['option'].'['.$args['name'].'_include_replies]'; ?>" id="ctf_include_replies" type="checkbox" <?php if ( $show_replies ) echo "checked"; ?> />
1058
- <label class="ctf-radio-label" for="ctf_include_replies"><?php _e( 'include replies', 'custom-twitter-feed' ); ?></label>
1059
  <?php do_action( 'ctf_admin_upgrade_note' ); ?>
1060
  </span>
1061
  <?php endif; ?>
@@ -1075,8 +1079,8 @@ class CtfAdmin
1075
  <input name="<?php echo $args['option'].'['.$args['name'].'_text'.']'; ?>" id="ctf_<?php echo $args['name'].'_text'; ?>" type="text" value="<?php esc_attr_e( $option_string ); ?>" size="25" />
1076
  <?php endif; ?>
1077
  <?php if ( isset( $args['whatis'] ) ) : ?>
1078
- <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feed' ); ?></a>
1079
- <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feed' ); ?>.</p>
1080
  <?php endif; ?>
1081
  <?php
1082
  do_action( 'ctf_admin_feed_settings_search_extra' );
@@ -1098,9 +1102,9 @@ class CtfAdmin
1098
  <?php if ( $args['name'] == 'width' ) :
1099
  $checked = ( isset( $options[ $args['name'] . '_mobile_no_fixed' ] ) ) ? esc_attr( $options[ $args['name'] . '_mobile_no_fixed' ] ) : false; ?>
1100
  <div id="ctf_width_options">
1101
- <input name="<?php echo $args['option'].'[width_mobile_no_fixed]'; ?>" type="checkbox" id="ctf_width_mobile_no_fixed" <?php if ( $checked == true ) { echo "checked"; }?> /><label for="ctf_width_mobile_no_fixed"><?php _e('Set to be 100% width on mobile?', 'custom-twitter-feed'); ?></label>
1102
  <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e('What does this mean?', 'custom-facebook-feed'); ?></a>
1103
- <p class="ctf-tooltip ctf-more-info"><?php _e("If you set a width on the feed then this will be used on mobile as well as desktop. Check this setting to set the feed width to be 100% on mobile so that it is responsive.", 'custom-twitter-feed'); ?></p>
1104
  </div>
1105
  <?php endif; ?>
1106
  <?php
@@ -1120,8 +1124,8 @@ class CtfAdmin
1120
  <option value="86400" <?php if ( $selected == "86400" ) echo 'selected="selected"' ?> ><?php esc_attr_e( 'Days' ); ?></option>
1121
  </select>&nbsp;
1122
  <input id="ctf-clear-cache" class="button-secondary" style="margin-top: 1px;" type="submit" value="<?php esc_attr_e( 'Clear Twitter Cache' ); ?>" />
1123
- <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feed' ); ?></a>
1124
- <p class="ctf-tooltip ctf-more-info"><?php _e( 'Clicking this button will clear all cached data for your Twitter feeds', 'custom-twitter-feed' ); ?>.</p>
1125
  <?php
1126
  }
1127
 
@@ -1139,8 +1143,8 @@ class CtfAdmin
1139
  <option value="5" <?php if ( $ctf_date_formatting == "5" ) echo 'selected="selected"'; ?> ><?php echo date( 'm.d.y', $original ); ?></option>
1140
  </select>
1141
  <?php if ( isset( $args['whatis'] ) ) : ?>
1142
- <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feed' ); ?></a>
1143
- <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feed' ); ?>.</p>
1144
  <?php endif; ?>
1145
  <?php
1146
  }
@@ -1151,7 +1155,7 @@ class CtfAdmin
1151
  $option_string = ( isset( $options[ $args['name'] ] ) ) ? esc_attr( $options[ $args['name'] ] ) : '';
1152
  ?>
1153
  <input name="<?php echo $args['option'].'['.$args['name'].']'; ?>" id="ctf_<?php echo $args['name']; ?>" type="text" value="<?php esc_attr_e( $option_string ); ?>" size="10" placeholder="Eg. F jS, Y" />
1154
- <a href="https://smashballoon.com/custom-twitter-feed/docs/date/" class="cff-external-link" target="_blank"><?php _e( 'Examples' , 'custom-twitter-feed'); ?></a>
1155
  <?php
1156
  }
1157
 
@@ -1164,11 +1168,11 @@ class CtfAdmin
1164
 
1165
  ?>
1166
  <input name="<?php echo $args['option'].'[mtime]'; ?>" id="ctf_translate_minute" type="text" value="<?php esc_attr_e( $option_m ); ?>" size="5" />
1167
- <label for=ctf_translate_minute"><?php _e( 'translation for "m" (minutes)', 'custom-twitter-feed' ); ?></label><br>
1168
  <input name="<?php echo $args['option'].'[htime]'; ?>" id="ctf_translate_hour" type="text" value="<?php esc_attr_e( $option_h ); ?>" size="5" />
1169
- <label for=ctf_translate_hour"><?php _e( 'translation for "h" (hours)', 'custom-twitter-feed' ); ?></label><br>
1170
  <input name="<?php echo $args['option'].'[nowtime]'; ?>" id="ctf_translate_now" type="text" value="<?php esc_attr_e( $option_now ); ?>" size="5" />
1171
- <label for=ctf_translate_now"><?php _e( 'translation for "now"', 'custom-twitter-feed' ); ?></label><br>
1172
  <?php
1173
  }
1174
 
@@ -1183,7 +1187,7 @@ class CtfAdmin
1183
  <?php if ( $option_checked ) {
1184
  echo "checked";
1185
  } ?> />
1186
- <label for=ctf_<?php echo $field[0]; ?>"><?php _e( $field[1], 'custom-twitter-feed' ); ?></label><br>
1187
  <?php
1188
  } // end foreach
1189
  }
@@ -1213,8 +1217,8 @@ class CtfAdmin
1213
  <option value="60" <?php if ( $ctf_text_size == "60" ) echo 'selected="selected"' ?> >60px</option>
1214
  </select>
1215
  <?php if ( isset( $args['whatis'] ) ) : ?>
1216
- <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feed' ); ?></a>
1217
- <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feed' ); ?>.</p>
1218
  <?php endif; ?>
1219
  <?php
1220
  }
@@ -1230,8 +1234,8 @@ class CtfAdmin
1230
  <option value="bold" <?php if ( $ctf_text_weight == "bold" ) echo 'selected="selected"'; ?> >Bold</option>
1231
  </select>
1232
  <?php if ( isset( $args['whatis'] ) ) : ?>
1233
- <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feed' ); ?></a>
1234
- <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feed' ); ?>.</p>
1235
  <?php endif; ?>
1236
  <?php
1237
  }
@@ -1335,8 +1339,8 @@ class CtfAdmin
1335
  <option value="Pacific/Kiritimati" <?php if( $ctf_timezone == "Pacific/Kiritimati" ) echo 'selected="selected"' ?> ><?php _e( '(GMT+14:00) Kiritimati' ) ?></option>
1336
  </select>
1337
  <?php if ( isset( $args['whatis'] ) ) : ?>
1338
- <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feed' ); ?></a>
1339
- <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feed' ); ?>.</p>
1340
  <?php endif; ?>
1341
  <?php
1342
  }
@@ -1346,9 +1350,9 @@ class CtfAdmin
1346
  $options = get_option( $args['option'] );
1347
  $option_string = ( isset( $options[ $args['name'] ] ) ) ? esc_attr( $options[ $args['name'] ] ) : '';
1348
  ?>
1349
- <p><?php _e( $args['description'], 'custom-twitter-feed' ) ; ?></p>
1350
  <textarea name="<?php echo $args['option'].'['.$args['name'].']'; ?>" id="ctf_<?php echo $args['name']; ?>" style="width: 70%;" rows="7"><?php esc_attr_e( stripslashes( $option_string ) ); ?></textarea>
1351
- <?php if ( isset( $args['extra'] ) ) { _e( '<p class="ctf_note">'.$args['extra'].'</p>', 'custom-twitter-feed' ); } ?>
1352
  <?php
1353
  }
1354
 
21
  public function add_menu()
22
  {
23
  add_menu_page(
24
+ 'Twitter Feeds',
25
+ 'Twitter Feeds',
26
  'manage_options',
27
+ 'custom-twitter-feeds',
28
  array( $this, 'create_options_page' ),
29
  '',
30
  99
66
  <input name="<?php echo 'ctf_configure'.'[have_own_tokens]'; ?>" id="ctf_have_own_tokens" type="checkbox" <?php if ( $option_checked ) echo "checked"; ?> />
67
  <label for="ctf_have_own_tokens" class="ctf_checkbox"><?php _e( 'Or, manually enter my own Twitter app information' ); ?></label>
68
  <span class="ctf-tooltip-wrap">
69
+ <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feeds' ); ?></a>
70
+ <p class="ctf-tooltip ctf-more-info"><?php _e( 'Check this box if you would like to manually enter the information from your own <a href="https://smashballoon.com/custom-twitter-feeds/docs/create-twitter-app/" target="_blank">Twitter app</a>', 'custom-twitter-feeds' ); ?>.</p>
71
  </span>
72
  <?php
73
  }
83
  <div id="ctf_config">
84
 
85
  <?php if ( isset( $access_token_data['oauth_token'] ) ) : ?>
86
+ <a href="<?php echo OAUTH_PROCESSOR_URL . admin_url( 'admin.php?page=custom-twitter-feeds' ); ?>" id="ctf-get-token"><i class="fa fa-twitter"></i><?php _e( 'Log in to Twitter and get my Access Token and Secret' ); ?></a>
87
+ <a class="ctf-tooltip-link" href="https://smashballoon.com/custom-twitter-feeds/token/" target="_blank"><?php _e( "Button not working?", 'custom-twitter-feeds' ); ?></a>
88
+
89
  <input type="hidden" id="ctf-retrieved-access-token" value="<?php echo esc_html( sanitize_text_field( $access_token_data['oauth_token'] ) ); ?>">
90
  <input type="hidden" id="ctf-retrieved-access-token-secret" value="<?php echo esc_html( sanitize_text_field( $access_token_data['oauth_token_secret'] ) ); ?>">
91
  <input type="hidden" id="ctf-retrieved-default-screen-name" value="<?php echo esc_html( sanitize_text_field( $access_token_data['screen_name'] ) ); ?>">
92
 
93
  <?php elseif ( isset( $access_token_data['error'] ) && ! isset( $access_token_data['oauth_token'] ) ) : ?>
94
 
95
+ <p class="ctf_notice"><?php _e( 'There was an error with retrieving your access tokens. Please <a href="https://smashballoon.com/custom-twitter-feeds/token/" target="_blank">use this tool</a> to get your access token and secret.' ); ?></p><br>
96
+ <a href="<?php echo OAUTH_PROCESSOR_URL . admin_url( 'admin.php?page=custom-twitter-feeds' ); ?>" id="ctf-get-token"><i class="fa fa-twitter"></i><?php _e( 'Log in to Twitter and get my Access Token and Secret' ); ?></a>
97
+ <a class="ctf-tooltip-link" href="https://smashballoon.com/custom-twitter-feeds/token/" target="_blank"><?php _e( "Button not working?", 'custom-twitter-feeds' ); ?></a>
98
 
99
  <?php else : ?>
100
 
101
+ <a href="<?php echo OAUTH_PROCESSOR_URL . admin_url( 'admin.php?page=custom-twitter-feeds' ); ?>" id="ctf-get-token"><i class="fa fa-twitter"></i><?php _e( 'Log in to Twitter and get my Access Token and Secret' ); ?></a>
102
+ <a class="ctf-tooltip-link" href="https://smashballoon.com/custom-twitter-feeds/token/" target="_blank"><?php _e( "Button not working?", 'custom-twitter-feeds' ); ?></a>
103
+
104
  <?php endif; ?>
105
 
106
  </div>
135
  'section' => 'ctf_configure_connect', // matches the section name
136
  'option' => 'ctf_configure', // matches the options name
137
  'class' => 'ctf-toggle-consumer', // class for the wrapper and input field
138
+ 'whatis' => 'A Consumer Key and a Consumer Secret are both needed if you want to use credentials from your own Twitter App. You can create these <a href="https://smashballoon.com/custom-twitter-feeds/docs/create-twitter-app/" target="_blank">here</a>', // what is this? text
139
  'size' => '27'
140
  ) );
141
 
148
  'section' => 'ctf_configure_connect', // matches the section name
149
  'option' => 'ctf_configure', // matches the options name
150
  'class' => 'ctf-toggle-consumer', // class for the wrapper and input field
151
+ 'whatis' => 'A Consumer Key and a Consumer Secret are both needed if you want to use credentials from your own Twitter App. You can create these <a href="https://smashballoon.com/custom-twitter-feeds/docs/create-twitter-app/" target="_blank">here</a>', // what is this? text
152
  'size' => '57'
153
  ) );
154
 
437
  // credit ctf
438
  $this->create_settings_field( array(
439
  'name' => 'creditctf',
440
+ 'title' => '<label for="ctf_creditctf">Add Custom Twitter Feeds Credit</label><code class="ctf_shortcode">creditctf
441
  Eg: creditctf=true</code>', // label for the input field
442
  'callback' => 'default_checkbox', // name of the function that outputs the html
443
  'page' => 'ctf_customize_showandhide', // matches the section name
444
  'section' => 'ctf_customize_showandhide', // matches the section name
445
  'option' => 'ctf_customize', // matches the options name
446
  'class' => '',
447
+ 'whatis' => "Help us keep this plugin great! Add a link below your feed to credit Custom Twitter Feeds by Smash Balloon"
448
  ));
449
 
450
  add_settings_section(
722
  // header text color
723
  $this->create_settings_field( array(
724
  'name' => 'headertextcolor',
725
+ 'title' => '<label for="ctf_headertextcolor">Header Text Color</label><code class="ctf_shortcode">headertextcolor
726
  Eg: headertextcolor=#444</code>', // label for the input field
727
  'callback' => 'default_color', // name of the function that outputs the html
728
  'page' => 'ctf_style_header', // matches the section name
957
  <span><?php echo $args['example']; ?></span>
958
  <?php endif; ?>
959
  <?php if ( isset( $args['whatis'] ) ) : ?>
960
+ <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feeds' ); ?></a>
961
+ <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feeds' ); ?>.</p>
962
  <?php endif; ?>
963
  <?php
964
  }
970
  ?>
971
  <select name="<?php echo $args['option'].'['.$args['name'].']'; ?>" id="ctf_<?php echo $args['name']; ?>" class="<?php echo $args['class']; ?>">
972
  <?php foreach ( $args['fields'] as $field ) : ?>
973
+ <option value="<?php echo $field[0]; ?>" id="ctf-<?php echo $args['name']; ?>" class="<?php echo $args['class']; ?>"<?php if( $selected == $field[0] ) { echo ' selected'; } ?>><?php _e( $field[1], 'custom-twitter-feeds' ); ?></option>
974
  <?php endforeach; ?>
975
  </select>
976
  <?php if ( isset( $args['whatis'] ) ) : ?>
977
+ <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feeds' ); ?></a>
978
+ <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feeds' ); ?>.</p>
979
  <?php endif; ?>
980
  <?php
981
  }
996
  ?>
997
  <input name="<?php echo $args['option'].'['.$args['name'].']'; ?>" id="ctf_<?php echo $args['name']; ?>" type="checkbox" <?php if ( $option_checked ) echo "checked"; ?> />
998
  <?php if ( isset( $args['whatis'] ) ) : ?>
999
+ <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feeds' ); ?></a>
1000
+ <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feeds' ); ?>.</p>
1001
  <?php endif; ?>
1002
  <?php
1003
  }
1009
  ?>
1010
  <input name="<?php echo $args['option'].'['.$args['name'].']'; ?>" id="ctf_<?php echo $args['name']; ?>" type="checkbox" <?php if ( $option_checked ) echo "checked"; ?> />
1011
  <?php if ( isset( $args['whatis'] ) ) : ?>
1012
+ <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feeds' ); ?></a>
1013
+ <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feeds' ); ?>.</p>
1014
  <?php endif; ?>
1015
  <?php
1016
  }
1033
  <?php endif; ?>
1034
 
1035
  <?php if ( isset( $args['whatis'] ) ) : ?>
1036
+ <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feeds' ); ?></a>
1037
+ <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feeds' ); ?>.</p>
1038
  <?php endif; ?>
1039
 
1040
  <?php
1048
  $option_string = ( isset( $options[ $args['name'].'_text' ] ) ) ? esc_attr( $options[ $args['name'].'_text' ] ) : '';
1049
  ?>
1050
  <input type="radio" name="<?php echo $args['option'].'[type]'; ?>" class="ctf-feed-settings-radio" id="ctf_<?php echo $args['name'].'_radio'; ?>" value="<?php echo $args['name']; ?>" <?php if ( $option_checked ) echo "checked"; ?> />
1051
+ <label class="ctf-radio-label" for="ctf_<?php echo $args['name'].'_radio'; ?>"><?php _e( $args['label'], 'custom-twitter-feeds' ); ?></label>
1052
  <?php if ( $args['has_input'] ) : ?>
1053
  <input name="<?php echo $args['option'].'['.$args['name'].'_text'.']'; ?>" id="ctf_<?php echo $args['name'].'_text'; ?>" type="text" value="<?php esc_attr_e( $option_string ); ?>" size="25" />
1054
  <?php endif; ?>
1055
  <?php if ( isset( $args['whatis'] ) ) : ?>
1056
+ <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feeds' ); ?></a>
1057
+ <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feeds' ); ?>.</p>
1058
  <?php endif; ?>
1059
  <?php if ( $args['has_replies'] ) : ?>
1060
  <span class="ctf_include_replies_toggle ctf_pro">
1061
  <input name="<?php echo $args['option'].'['.$args['name'].'_include_replies]'; ?>" id="ctf_include_replies" type="checkbox" <?php if ( $show_replies ) echo "checked"; ?> />
1062
+ <label class="ctf-radio-label" for="ctf_include_replies"><?php _e( 'include replies', 'custom-twitter-feeds' ); ?></label>
1063
  <?php do_action( 'ctf_admin_upgrade_note' ); ?>
1064
  </span>
1065
  <?php endif; ?>
1079
  <input name="<?php echo $args['option'].'['.$args['name'].'_text'.']'; ?>" id="ctf_<?php echo $args['name'].'_text'; ?>" type="text" value="<?php esc_attr_e( $option_string ); ?>" size="25" />
1080
  <?php endif; ?>
1081
  <?php if ( isset( $args['whatis'] ) ) : ?>
1082
+ <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feeds' ); ?></a>
1083
+ <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feeds' ); ?>.</p>
1084
  <?php endif; ?>
1085
  <?php
1086
  do_action( 'ctf_admin_feed_settings_search_extra' );
1102
  <?php if ( $args['name'] == 'width' ) :
1103
  $checked = ( isset( $options[ $args['name'] . '_mobile_no_fixed' ] ) ) ? esc_attr( $options[ $args['name'] . '_mobile_no_fixed' ] ) : false; ?>
1104
  <div id="ctf_width_options">
1105
+ <input name="<?php echo $args['option'].'[width_mobile_no_fixed]'; ?>" type="checkbox" id="ctf_width_mobile_no_fixed" <?php if ( $checked == true ) { echo "checked"; }?> /><label for="ctf_width_mobile_no_fixed"><?php _e('Set to be 100% width on mobile?', 'custom-twitter-feeds'); ?></label>
1106
  <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e('What does this mean?', 'custom-facebook-feed'); ?></a>
1107
+ <p class="ctf-tooltip ctf-more-info"><?php _e("If you set a width on the feed then this will be used on mobile as well as desktop. Check this setting to set the feed width to be 100% on mobile so that it is responsive.", 'custom-twitter-feeds'); ?></p>
1108
  </div>
1109
  <?php endif; ?>
1110
  <?php
1124
  <option value="86400" <?php if ( $selected == "86400" ) echo 'selected="selected"' ?> ><?php esc_attr_e( 'Days' ); ?></option>
1125
  </select>&nbsp;
1126
  <input id="ctf-clear-cache" class="button-secondary" style="margin-top: 1px;" type="submit" value="<?php esc_attr_e( 'Clear Twitter Cache' ); ?>" />
1127
+ <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feeds' ); ?></a>
1128
+ <p class="ctf-tooltip ctf-more-info"><?php _e( 'Clicking this button will clear all cached data for your Twitter feeds', 'custom-twitter-feeds' ); ?>.</p>
1129
  <?php
1130
  }
1131
 
1143
  <option value="5" <?php if ( $ctf_date_formatting == "5" ) echo 'selected="selected"'; ?> ><?php echo date( 'm.d.y', $original ); ?></option>
1144
  </select>
1145
  <?php if ( isset( $args['whatis'] ) ) : ?>
1146
+ <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feeds' ); ?></a>
1147
+ <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feeds' ); ?>.</p>
1148
  <?php endif; ?>
1149
  <?php
1150
  }
1155
  $option_string = ( isset( $options[ $args['name'] ] ) ) ? esc_attr( $options[ $args['name'] ] ) : '';
1156
  ?>
1157
  <input name="<?php echo $args['option'].'['.$args['name'].']'; ?>" id="ctf_<?php echo $args['name']; ?>" type="text" value="<?php esc_attr_e( $option_string ); ?>" size="10" placeholder="Eg. F jS, Y" />
1158
+ <a href="https://smashballoon.com/custom-twitter-feeds/docs/date/" class="cff-external-link" target="_blank"><?php _e( 'Examples' , 'custom-twitter-feeds'); ?></a>
1159
  <?php
1160
  }
1161
 
1168
 
1169
  ?>
1170
  <input name="<?php echo $args['option'].'[mtime]'; ?>" id="ctf_translate_minute" type="text" value="<?php esc_attr_e( $option_m ); ?>" size="5" />
1171
+ <label for=ctf_translate_minute"><?php _e( 'translation for "m" (minutes)', 'custom-twitter-feeds' ); ?></label><br>
1172
  <input name="<?php echo $args['option'].'[htime]'; ?>" id="ctf_translate_hour" type="text" value="<?php esc_attr_e( $option_h ); ?>" size="5" />
1173
+ <label for=ctf_translate_hour"><?php _e( 'translation for "h" (hours)', 'custom-twitter-feeds' ); ?></label><br>
1174
  <input name="<?php echo $args['option'].'[nowtime]'; ?>" id="ctf_translate_now" type="text" value="<?php esc_attr_e( $option_now ); ?>" size="5" />
1175
+ <label for=ctf_translate_now"><?php _e( 'translation for "now"', 'custom-twitter-feeds' ); ?></label><br>
1176
  <?php
1177
  }
1178
 
1187
  <?php if ( $option_checked ) {
1188
  echo "checked";
1189
  } ?> />
1190
+ <label for=ctf_<?php echo $field[0]; ?>"><?php _e( $field[1], 'custom-twitter-feeds' ); ?></label><br>
1191
  <?php
1192
  } // end foreach
1193
  }
1217
  <option value="60" <?php if ( $ctf_text_size == "60" ) echo 'selected="selected"' ?> >60px</option>
1218
  </select>
1219
  <?php if ( isset( $args['whatis'] ) ) : ?>
1220
+ <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feeds' ); ?></a>
1221
+ <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feeds' ); ?>.</p>
1222
  <?php endif; ?>
1223
  <?php
1224
  }
1234
  <option value="bold" <?php if ( $ctf_text_weight == "bold" ) echo 'selected="selected"'; ?> >Bold</option>
1235
  </select>
1236
  <?php if ( isset( $args['whatis'] ) ) : ?>
1237
+ <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feeds' ); ?></a>
1238
+ <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feeds' ); ?>.</p>
1239
  <?php endif; ?>
1240
  <?php
1241
  }
1339
  <option value="Pacific/Kiritimati" <?php if( $ctf_timezone == "Pacific/Kiritimati" ) echo 'selected="selected"' ?> ><?php _e( '(GMT+14:00) Kiritimati' ) ?></option>
1340
  </select>
1341
  <?php if ( isset( $args['whatis'] ) ) : ?>
1342
+ <a class="ctf-tooltip-link" href="JavaScript:void(0);"><?php _e( "What is this?", 'custom-twitter-feeds' ); ?></a>
1343
+ <p class="ctf-tooltip ctf-more-info"><?php _e( $args['whatis'], 'custom-twitter-feeds' ); ?>.</p>
1344
  <?php endif; ?>
1345
  <?php
1346
  }
1350
  $options = get_option( $args['option'] );
1351
  $option_string = ( isset( $options[ $args['name'] ] ) ) ? esc_attr( $options[ $args['name'] ] ) : '';
1352
  ?>
1353
+ <p><?php _e( $args['description'], 'custom-twitter-feeds' ) ; ?></p>
1354
  <textarea name="<?php echo $args['option'].'['.$args['name'].']'; ?>" id="ctf_<?php echo $args['name']; ?>" style="width: 70%;" rows="7"><?php esc_attr_e( stripslashes( $option_string ) ); ?></textarea>
1355
+ <?php if ( isset( $args['extra'] ) ) { _e( '<p class="ctf_note">'.$args['extra'].'</p>', 'custom-twitter-feeds' ); } ?>
1356
  <?php
1357
  }
1358
 
inc/CtfFeed.php CHANGED
@@ -773,7 +773,7 @@ class CtfFeed
773
  $html = '';
774
 
775
  $html .= '<div class="ctf-out-of-tweets">';
776
- $html .= '<p>'. _e( "That's all! No more Tweets to load", 'custom-twitter-feed' ).'</p>';
777
  $html .= '<p>';
778
  $html .= '<a class="twitter-share-button" href="https://twitter.com/share" target="_blank" data-size="large" data-url="<?php echo get_home_url(); ?>">Share</a>';
779
  if ( isset( $feed_options['screenname'] ) ) {
@@ -798,7 +798,7 @@ class CtfFeed
798
  $ctf_feed_classes = apply_filters( 'ctf_feed_classes', $ctf_feed_classes ); //add_filter( 'ctf_feed_classes', function( $ctf_feed_classes ) { return $ctf_feed_classes . ' new-class'; }, 10, 1 );
799
  $ctf_feed_html = '';
800
 
801
- $ctf_feed_html .= '<!-- Custom Twitter Feed by Smash Balloon -->';
802
  $ctf_feed_html .= '<div id="ctf" class="' . $ctf_feed_classes . '" style="' . $feed_options['width'] . $feed_options['height'] . $feed_options['bgcolor'] . '" data-ctfshortcode="' . $this->getShortCodeJSON() . '"' .$ctf_data_disablelinks . $ctf_data_linktextcolor . '>';
803
  $tweet_set = $this->tweet_set;
804
 
@@ -816,7 +816,7 @@ class CtfFeed
816
  }
817
 
818
  if ( $feed_options['creditctf'] ) {
819
- $ctf_feed_html .= '<div class="ctf-credit-link"><a href="https://smashballoon.com/custom-twitter-feed" target="_blank"><i class="fa fa-twitter" aria-hidden="true"></i>The Custom Twitter Feed Plugin</a></div>';
820
  }
821
 
822
  $ctf_feed_html .= '</div>';
@@ -831,12 +831,13 @@ class CtfFeed
831
  protected function getFeedHeaderHtml( $tweet_set, $feed_options )
832
  {
833
  $ctf_header_html = '';
 
834
 
835
  if ( $feed_options['type'] === 'usertimeline' ) {
836
- $ctf_header_html .= '<div class="ctf-header">';
837
  $ctf_header_html .= '<a href="http://twitter.com/' . $tweet_set[0]['user']['screen_name'] . '" target="_blank" title="@' . $tweet_set[0]['user']['screen_name'] . '" class="ctf-header-link">';
838
  $ctf_header_html .= '<div class="ctf-header-text">';
839
- $ctf_header_html .= '<p class="ctf-header-user">';
840
  $ctf_header_html .= '<span class="ctf-header-name">';
841
 
842
  if ( $feed_options['headertext'] != '' ) {
@@ -855,7 +856,7 @@ class CtfFeed
855
  $ctf_header_html .= '</p>';
856
 
857
  if ( $feed_options['showbio'] ) {
858
- $ctf_header_html .= '<p class="ctf-header-bio">' . $tweet_set[0]['user']['description'] . '</p>';
859
  }
860
 
861
  $ctf_header_html .= '</div>';
@@ -875,10 +876,10 @@ class CtfFeed
875
  $url_part = $feed_options['screenname']; //Need to get screenname here
876
  }
877
 
878
- $ctf_header_html .= '<div class="ctf-header ctf-header-type-generic">';
879
  $ctf_header_html .= '<a href="https://twitter.com/' . $url_part . '" target="_blank" class="ctf-header-link">';
880
  $ctf_header_html .= '<div class="ctf-header-text">';
881
- $ctf_header_html .= '<p class="ctf-header-no-bio">' . $default_header_text . '</p>';
882
  $ctf_header_html .= '</div>';
883
  $ctf_header_html .= '<div class="ctf-header-img">';
884
  $ctf_header_html .= '<div class="ctf-header-generic-icon">';
@@ -1067,7 +1068,7 @@ class CtfFeed
1067
  $error_html .= 'The error response from the Twitter API is the following:<br />';
1068
  $error_html .= '<code>Error number: ' . $this->api_obj->api_error_no . '<br />';
1069
  $error_html .= 'Message: ' . $this->api_obj->api_error_message . '</code>';
1070
- $error_html .= '<a href="https://smashballoon.com/custom-twitter-feed/support" target="_blank">Click here to troubleshoot</a></p>';
1071
  }
1072
 
1073
  $error_html .= '</div>';
773
  $html = '';
774
 
775
  $html .= '<div class="ctf-out-of-tweets">';
776
+ $html .= '<p>That\'s all! No more Tweets to load</p>';
777
  $html .= '<p>';
778
  $html .= '<a class="twitter-share-button" href="https://twitter.com/share" target="_blank" data-size="large" data-url="<?php echo get_home_url(); ?>">Share</a>';
779
  if ( isset( $feed_options['screenname'] ) ) {
798
  $ctf_feed_classes = apply_filters( 'ctf_feed_classes', $ctf_feed_classes ); //add_filter( 'ctf_feed_classes', function( $ctf_feed_classes ) { return $ctf_feed_classes . ' new-class'; }, 10, 1 );
799
  $ctf_feed_html = '';
800
 
801
+ $ctf_feed_html .= '<!-- Custom Twitter Feeds by Smash Balloon -->';
802
  $ctf_feed_html .= '<div id="ctf" class="' . $ctf_feed_classes . '" style="' . $feed_options['width'] . $feed_options['height'] . $feed_options['bgcolor'] . '" data-ctfshortcode="' . $this->getShortCodeJSON() . '"' .$ctf_data_disablelinks . $ctf_data_linktextcolor . '>';
803
  $tweet_set = $this->tweet_set;
804
 
816
  }
817
 
818
  if ( $feed_options['creditctf'] ) {
819
+ $ctf_feed_html .= '<div class="ctf-credit-link"><a href="https://smashballoon.com/custom-twitter-feeds" target="_blank"><iclass="fa fa-twitter" aria-hidden="true"></i>Custom Twitter Feeds Plugin</a></div>';
820
  }
821
 
822
  $ctf_feed_html .= '</div>';
831
  protected function getFeedHeaderHtml( $tweet_set, $feed_options )
832
  {
833
  $ctf_header_html = '';
834
+ $ctf_no_bio = $feed_options['showbio'] ? '' : ' ctf-no-bio';
835
 
836
  if ( $feed_options['type'] === 'usertimeline' ) {
837
+ $ctf_header_html .= '<div class="ctf-header' . $ctf_no_bio . '" style="' . $feed_options['headerbgcolor'] . '">';
838
  $ctf_header_html .= '<a href="http://twitter.com/' . $tweet_set[0]['user']['screen_name'] . '" target="_blank" title="@' . $tweet_set[0]['user']['screen_name'] . '" class="ctf-header-link">';
839
  $ctf_header_html .= '<div class="ctf-header-text">';
840
+ $ctf_header_html .= '<p class="ctf-header-user" style="' . $feed_options['headertextcolor'] . '">';
841
  $ctf_header_html .= '<span class="ctf-header-name">';
842
 
843
  if ( $feed_options['headertext'] != '' ) {
856
  $ctf_header_html .= '</p>';
857
 
858
  if ( $feed_options['showbio'] ) {
859
+ $ctf_header_html .= '<p class="ctf-header-bio" style="' . $feed_options['headertextcolor'] . '">' . $tweet_set[0]['user']['description'] . '</p>';
860
  }
861
 
862
  $ctf_header_html .= '</div>';
876
  $url_part = $feed_options['screenname']; //Need to get screenname here
877
  }
878
 
879
+ $ctf_header_html .= '<div class="ctf-header ctf-header-type-generic" style="' . $feed_options['headerbgcolor'] . '">';
880
  $ctf_header_html .= '<a href="https://twitter.com/' . $url_part . '" target="_blank" class="ctf-header-link">';
881
  $ctf_header_html .= '<div class="ctf-header-text">';
882
+ $ctf_header_html .= '<p class="ctf-header-no-bio" style="' . $feed_options['headertextcolor'] . '">' . $default_header_text . '</p>';
883
  $ctf_header_html .= '</div>';
884
  $ctf_header_html .= '<div class="ctf-header-img">';
885
  $ctf_header_html .= '<div class="ctf-header-generic-icon">';
1068
  $error_html .= 'The error response from the Twitter API is the following:<br />';
1069
  $error_html .= '<code>Error number: ' . $this->api_obj->api_error_no . '<br />';
1070
  $error_html .= 'Message: ' . $this->api_obj->api_error_message . '</code>';
1071
+ $error_html .= '<a href="https://smashballoon.com/custom-twitter-feeds/support" target="_blank">Click here to troubleshoot</a></p>';
1072
  }
1073
 
1074
  $error_html .= '</div>';
inc/admin-hooks.php CHANGED
@@ -51,7 +51,7 @@ function ctf_return_feed_types( $val ) {
51
  add_action( 'ctf_admin_upgrade_note', 'ctf_update_note' );
52
  function ctf_update_note() {
53
  ?>
54
- <span class="ctf_note"> - <a href="https://smashballoon.com/custom-twitter-feed/" target="_blank">Pro version coming soon</a></span>
55
  <?php
56
  }
57
 
@@ -60,7 +60,7 @@ function ctf_usertimeline_error_message( $args )
60
  { //sbi_notice sbi_user_id_error
61
  if ( $args['name'] == 'usertimeline') : ?>
62
  <div class="ctf_notice ctf_usertimeline_error">
63
- <?php _e( "<p>Please use a single screenname or Twitter handle of numbers and letters. If you would like to use more than one screen name for your feed, please upgrade to our <a href='https://smashballoon.com/custom-twitter-feed/' target='_blank'>Pro version</a> (coming soon).</p>" ); ?>
64
  </div>
65
  <?php endif;
66
  }
@@ -69,7 +69,7 @@ add_action( 'ctf_admin_feed_settings_search_extra', 'ctf_hashtag_error_message'
69
  function ctf_hashtag_error_message() {
70
  ?>
71
  <div class="ctf_notice ctf_search_error">
72
- <?php _e( "<p>Please use a single hashtag of numbers and letters. If you would like to use more than one hashtag or use search terms for your feed, please upgrade to our <a href='https://smashballoon.com/custom-twitter-feed/' target='_blank'>Pro version</a> (coming soon).</p>" ); ?>
73
  </div>
74
  <?php
75
  }
51
  add_action( 'ctf_admin_upgrade_note', 'ctf_update_note' );
52
  function ctf_update_note() {
53
  ?>
54
+ <span class="ctf_note"> - <a href="https://smashballoon.com/custom-twitter-feeds/" target="_blank">Pro version coming soon</a></span>
55
  <?php
56
  }
57
 
60
  { //sbi_notice sbi_user_id_error
61
  if ( $args['name'] == 'usertimeline') : ?>
62
  <div class="ctf_notice ctf_usertimeline_error">
63
+ <?php _e( "<p>Please use a single screenname or Twitter handle of numbers and letters. If you would like to use more than one screen name for your feed, please upgrade to our <a href='https://smashballoon.com/custom-twitter-feeds/' target='_blank'>Pro version</a> (coming soon).</p>" ); ?>
64
  </div>
65
  <?php endif;
66
  }
69
  function ctf_hashtag_error_message() {
70
  ?>
71
  <div class="ctf_notice ctf_search_error">
72
+ <?php _e( "<p>Please use a single hashtag of numbers and letters. If you would like to use more than one hashtag or use search terms for your feed, please upgrade to our <a href='https://smashballoon.com/custom-twitter-feeds/' target='_blank'>Pro version</a> (coming soon).</p>" ); ?>
73
  </div>
74
  <?php
75
  }
inc/widget.php CHANGED
@@ -2,23 +2,23 @@
2
  /**
3
  * Class CtfWidget
4
  *
5
- * Creates a text widget with the custom-twitter-feed shortcode inside
6
  */
7
 
8
  class CtfWidget extends WP_Widget
9
  {
10
  function __construct() {
11
  parent::__construct(
12
- 'custom-twitter-feed-widget',
13
- __( 'Custom Twitter Feed', 'custom-twitter-feed' ),
14
- array( 'description' => __( 'Display your Twitter feed', 'custom-twitter-feed' ), )
15
  );
16
  }
17
 
18
  public function widget( $args, $instance ) {
19
 
20
  $title = isset( $instance['title'] ) ? apply_filters( 'widget_title', $instance['title'] ) : '';
21
- $content = isset( $instance['content'] ) ? esc_html( $instance['content'] ) : '[custom-twitter-feed]';
22
 
23
  echo $args['before_widget'];
24
 
@@ -34,7 +34,7 @@ class CtfWidget extends WP_Widget
34
  public function form( $instance ) {
35
 
36
  $title = isset( $instance['title'] ) ? $instance['title'] : '';
37
- $content = isset ( $instance['content'] ) ? esc_html( $instance['content'] ) : '[custom-twitter-feed]';
38
  ?>
39
  <p>
40
  <label for="<?php echo esc_attr( $this->get_field_id( 'title' ) ); ?>"><?php _e( 'Title:' ); ?></label>
2
  /**
3
  * Class CtfWidget
4
  *
5
+ * Creates a text widget with the custom-twitter-feeds shortcode inside
6
  */
7
 
8
  class CtfWidget extends WP_Widget
9
  {
10
  function __construct() {
11
  parent::__construct(
12
+ 'custom-twitter-feeds-widget',
13
+ __( 'Custom Twitter Feeds', 'custom-twitter-feeds' ),
14
+ array( 'description' => __( 'Display your Twitter feed', 'custom-twitter-feeds' ), )
15
  );
16
  }
17
 
18
  public function widget( $args, $instance ) {
19
 
20
  $title = isset( $instance['title'] ) ? apply_filters( 'widget_title', $instance['title'] ) : '';
21
+ $content = isset( $instance['content'] ) ? esc_html( $instance['content'] ) : '[custom-twitter-feeds]';
22
 
23
  echo $args['before_widget'];
24
 
34
  public function form( $instance ) {
35
 
36
  $title = isset( $instance['title'] ) ? $instance['title'] : '';
37
+ $content = isset ( $instance['content'] ) ? esc_html( $instance['content'] ) : '[custom-twitter-feeds]';
38
  ?>
39
  <p>
40
  <label for="<?php echo esc_attr( $this->get_field_id( 'title' ) ); ?>"><?php _e( 'Title:' ); ?></label>
views/admin/configure.php CHANGED
@@ -8,4 +8,4 @@ settings_errors(); ?>
8
  <?php do_settings_sections('ctf_configure_feed_settings'); // matches the section name ?>
9
  <p class="submit"><input class="button-primary" type="submit" name="save" value="<?php esc_attr_e( 'Save Changes' ); ?>" /></p>
10
  </form>
11
- <p><i class="fa fa-chevron-circle-right" aria-hidden="true"></i>&nbsp; <?php _e('Next Step: <a href="?page=custom-twitter-feed&tab=customize">Customize your Feed</a>'); ?></p>
8
  <?php do_settings_sections('ctf_configure_feed_settings'); // matches the section name ?>
9
  <p class="submit"><input class="button-primary" type="submit" name="save" value="<?php esc_attr_e( 'Save Changes' ); ?>" /></p>
10
  </form>
11
+ <p><i class="fa fa-chevron-circle-right" aria-hidden="true"></i>&nbsp; <?php _e('Next Step: <a href="?page=custom-twitter-feeds&tab=customize">Customize your Feed</a>'); ?></p>
views/admin/customize.php CHANGED
@@ -31,4 +31,4 @@ settings_errors(); ?>
31
  <?php do_settings_sections('ctf_customize_advanced'); // matches the section name ?>
32
  <p class="submit"><input class="button-primary" type="submit" name="save" value="<?php esc_attr_e( 'Save Changes' ); ?>" /></p>
33
  </form>
34
- <p><i class="fa fa-chevron-circle-right" aria-hidden="true"></i>&nbsp; <?php _e('<b>Next Step:</b> <a href="?page=custom-twitter-feed&tab=style">Style your Feed</a>'); ?></p>
31
  <?php do_settings_sections('ctf_customize_advanced'); // matches the section name ?>
32
  <p class="submit"><input class="button-primary" type="submit" name="save" value="<?php esc_attr_e( 'Save Changes' ); ?>" /></p>
33
  </form>
34
+ <p><i class="fa fa-chevron-circle-right" aria-hidden="true"></i>&nbsp; <?php _e('<b>Next Step:</b> <a href="?page=custom-twitter-feeds&tab=style">Style your Feed</a>'); ?></p>
views/admin/display.php CHANGED
@@ -1,246 +1,246 @@
1
  <?php ?>
2
 
3
- <h3><?php _e( 'Display your Feed', 'custom-twitter-feed' ); ?></h3>
4
- <p><?php _e( "Copy and paste the following shortcode directly into the page, post or widget where you'd like the feed to show up:", 'custom-twitter-feed' ); ?></p>
5
- <input type="text" value="[custom-twitter-feed]" size="20" readonly="readonly" style="text-align: center;" onclick="this.focus();this.select()" title="<?php _e( 'To copy, click the field then press Ctrl + C (PC) or Cmd + C (Mac).', 'custom-twitter-feed' ); ?>" />
6
 
7
- <h3 style="padding-top: 10px;"><?php _e( 'Multiple Feeds', 'custom-twitter-feed' ); ?></h3>
8
- <p><?php _e( "If you'd like to display multiple feeds then you can set different settings directly in the shortcode like so:", 'custom-twitter-feed' ); ?>
9
- </br><code>[custom-twitter-feed screenname=gopro num=9]</code></p>
10
- <p><?php _e( "You can display as many different feeds as you like, on either the same page or on different pages, by just using the shortcode options below. For example:", 'custom-twitter-feed' ); ?><br />
11
- <code>[custom-twitter-feed]</code><br />
12
- <code>[custom-twitter-feed screenname="ANOTHER_SCREEN_NAME"]</code><br />
13
- <code>[custom-twitter-feed hashtag="#YOUR_HASHTAG" num=4 showfollow=false]</code>
14
  </p>
15
- <p><?php _e( "See the table below for a full list of available shortcode options:", 'custom-twitter-feed' ); ?></p>
16
 
17
- <!-- <p><span class="ctf_table_key"></span><?php _e( 'Pro version only', 'custom-twitter-feed' ); ?></p> -->
18
 
19
  <table class="ctf_shortcode_table">
20
  <tbody>
21
  <tr valign="top">
22
- <th scope="row"><?php _e( 'Shortcode option', 'custom-twitter-feed' ); ?></th>
23
- <th scope="row"><?php _e( 'Description', 'custom-twitter-feed' ); ?></th>
24
- <th scope="row"><?php _e( 'Example', 'custom-twitter-feed' ); ?></th>
25
  </tr>
26
 
27
- <tr class="ctf_table_header"><td colspan=3><?php _e( "Configure Options", 'custom-twitter-feed' ); ?></td></tr>
28
  <tr>
29
  <td>screenname</td>
30
- <td><?php _e( 'A user account name/Twitter handle. This will generate a user timeline feed', 'custom-twitter-feed' ); ?></td>
31
- <td><code>[custom-twitter-feed screenname="gopro"]</code></td>
32
  </tr>
33
  <tr>
34
  <td>hashtag</td>
35
- <td><?php _e( 'Any hashtag. This will generate a hashtag feed', 'custom-twitter-feed' ); ?></td>
36
- <td><code>[custom-twitter-feed hashtag="#awesome"]</code></td>
37
  </tr>
38
  <tr>
39
  <td>home</td>
40
- <td><?php _e( 'A home timeline will automatically use the account attached to your access token credentials', 'custom-twitter-feed' ); ?></td>
41
- <td><code>[custom-twitter-feed home=true]</code></td>
42
  </tr>
43
  <!-- <tr class="ctf_pro">
44
  <td>type</td>
45
- <td><?php _e( "Display tweets from multiple user accounts/Twitter handles<br />Display tweets from multiple hashtags/search terms<br />Display tweets that \"@\" mention your account", 'custom-twitter-feed' ); ?></td>
46
- <td><code>[custom-twitter-feed screenname="gopro, NBA"]</code><br /><code>[custom-twitter-feed search="#awesome+@nba"]</code><br/><code>[custom-twitter-feed mentions=true]</code></td>
47
  </tr>
48
  <tr class="ctf_pro">
49
  <td>user</td>
50
- <td><?php _e( 'A user account name/Twitter handle, separated by commas', 'custom-twitter-feed' ); ?></td>
51
- <td><code>[custom-twitter-feed screenname="gopro, NBA"]</code></td>
52
  </tr>
53
  <tr class="ctf_pro">
54
  <td>searchterm</td>
55
- <td><?php _e( 'Any search term or terms. Separate multiple terms by "+".', 'custom-twitter-feed' ); ?></td>
56
- <td><code>[custom-twitter-feed search="#awesome+@nba"]</code></td>
57
  </tr>
58
  <tr class="ctf_pro">
59
  <td>(no argument needed)</td>
60
- <td><?php _e( 'A mentions timeline will automatically use the account attached to your access token credentials', 'custom-twitter-feed' ); ?></td>
61
- <td><code>[custom-twitter-feed mentions=true]</code></td>
62
  </tr> -->
63
  <tr>
64
  <td>num</td>
65
- <td><?php _e( 'Number of Tweets to display', 'custom-twitter-feed' ); ?></td>
66
- <td><code>[custom-twitter-feed num=20]</code></td>
67
  </tr>
68
 
69
- <tr class="ctf_table_header"><td colspan=3><?php _e("Customize Options", 'custom-twitter-feed' ); ?></td></tr>
70
  <tr>
71
  <td>class</td>
72
- <td><?php _e( "A custom CSS class added to the feed", 'custom-twitter-feed' ); ?></td>
73
- <td><code>[custom-twitter-feed class="my-class"]</code></td>
74
  </tr>
75
  <tr>
76
  <td>headertext</td>
77
- <td><?php _e( "Custom text for the header", 'custom-twitter-feed' ); ?></td>
78
- <td><code>[custom-twitter-feed headertext="My Tweets"]</code></td>
79
  </tr>
80
- <tr class="ctf_table_header"><td colspan=3><?php _e("Show/Hide Options", 'custom-twitter-feed' ); ?></td></tr>
81
  <tr>
82
  <td>showheader</td>
83
- <td><?php _e( "Include a header for this feed", 'custom-twitter-feed' ); ?></td>
84
- <td><code>[custom-twitter-feed showheader=true]</code></td>
85
  </tr>
86
  <tr>
87
  <td>include</td>
88
- <td><?php _e( "Parts of the Tweet to include in the feed", 'custom-twitter-feed' ); ?></td>
89
- <td><code>[custom-twitter-feed include="author,date,text,avatar"]</code></td>
90
  </tr>
91
  <tr>
92
  <td>exclude</td>
93
- <td><?php _e( "Parts of the Tweet to exclude in the feed", 'custom-twitter-feed' ); ?></td>
94
- <td><code>[custom-twitter-feed exclude="retweeter,actions,linkbox,twitterlink"]</code></td>
95
  </tr>
96
  <tr>
97
  <td>creditctf</td>
98
- <td><?php _e( "Include a credit link to the Custom Twitter Feed homepage at the bottom of the feed", 'custom-twitter-feed' ); ?></td>
99
- <td><code>[custom-twitter-feed creditctf=true]</code></td>
100
  </tr>
101
  <tr>
102
  <td>showbutton</td>
103
- <td><?php _e( "Show the button that loads more tweets", 'custom-twitter-feed' ); ?></td>
104
- <td><code>[custom-twitter-feed showbutton=false]</code></td>
105
  </tr>
106
- <tr class="ctf_table_header"><td colspan=3><?php _e("Date Options", 'custom-twitter-feed' ); ?></td></tr>
107
  <tr>
108
  <td>dateformat</td>
109
- <td><?php _e( "Number of one of the default date formats", 'custom-twitter-feed' ); ?></td>
110
- <td><code>[custom-twitter-feed dateformat=3]</code></td>
111
  </tr>
112
  <tr>
113
  <td>datecustom</td>
114
- <td><?php _e( "Manually entered custom date format", 'custom-twitter-feed' ); ?></td>
115
- <td><code>[custom-twitter-feed datecustom="D M jS, Y"]</code></td>
116
  </tr>
117
  <tr>
118
  <td>mtime</td>
119
- <td><?php _e( "Translation for \"m\" time unit (English minute)", 'custom-twitter-feed' ); ?></td>
120
- <td><code>[custom-twitter-feed mtime="M"]</code></td>
121
  </tr>
122
  <tr>
123
  <td>htime</td>
124
- <td><?php _e( "Translation for \"h\" time unit (English hour)", 'custom-twitter-feed' ); ?></td>
125
- <td><code>[custom-twitter-feed htime="S"]</code></td>
126
  </tr>
127
  <tr>
128
  <td>nowtime</td>
129
- <td><?php _e( "Translation for English \"now\"", 'custom-twitter-feed' ); ?></td>
130
- <td><code>[custom-twitter-feed nowtime="jetzt"]</code></td>
131
  </tr>
132
- <tr class="ctf_table_header"><td colspan=3><?php _e("Link Options", 'custom-twitter-feed' ); ?></td></tr>
133
  <tr>
134
  <td>disablelinks</td>
135
- <td><?php _e( "Disable the links in the text of the tweet", 'custom-twitter-feed' ); ?></td>
136
- <td><code>[custom-twitter-feed disablelinks=false]</code></td>
137
  </tr>
138
  <tr>
139
  <td>linktexttotwitter</td>
140
- <td><?php _e( "Link the tweet text to Twitter", 'custom-twitter-feed' ); ?></td>
141
- <td><code>[custom-twitter-feed linktexttotwitter=false]</code></td>
142
  </tr>
143
  <tr>
144
  <td>twitterlinktext</td>
145
- <td><?php _e( "Custom text for the Twitter link", 'custom-twitter-feed' ); ?></td>
146
- <td><code>[custom-twitter-feed twitterlinktext="view on Twitter"]</code></td>
147
  </tr>
148
  <tr>
149
  <td>multiplier</td>
150
- <td><?php _e( 'A multiplying factor 1-3 to help with tweet filtering', 'custom-twitter-feed' ); ?></td>
151
- <td><code>[custom-twitter-feed multiplier=2.25]</code></td>
152
  </tr>
153
 
154
- <tr class="ctf_table_header"><td colspan=3><?php _e("Style Options", 'custom-twitter-feed' ); ?></td></tr>
155
  <tr>
156
  <td>width</td>
157
- <td><?php _e( "The width of your feed. Any number with a unit like \"px\" or \"%\".", 'custom-twitter-feed' ); ?></td>
158
- <td><code>[custom-twitter-feed width=400px]</code></td>
159
  </tr>
160
  <tr>
161
  <td>height</td>
162
- <td><?php _e( "The height of your feed. Any number with a unit like \"px\" or \"em\".", 'custom-twitter-feed' ); ?></td>
163
- <td><code>[custom-twitter-feed height=500px]</code></td>
164
  </tr>
165
  <tr>
166
  <td>bgcolor</td>
167
- <td><?php _e( "Background color for the feed. Any hex color code", 'custom-twitter-feed' ); ?></td>
168
- <td><code>[custom-twitter-feed bgcolor="eee"]</code></td>
169
  </tr>
170
  <tr>
171
  <td>tweetbgcolor</td>
172
- <td><?php _e( "Background color for each tweet. Any hex color code", 'custom-twitter-feed' ); ?></td>
173
- <td><code>[custom-twitter-feed tweetbgcolor="ddd"]</code></td>
174
  </tr>
175
- <tr class="ctf_table_header"><td colspan=3><?php _e("Typography Options", 'custom-twitter-feed' ); ?></td></tr>
176
  <tr>
177
  <td>authortextsize</td>
178
- <td><?php _e( "Size of author info font in pixels", 'custom-twitter-feed' ); ?></td>
179
- <td><code>[custom-twitter-feed authortextsize="16"]</code></td>
180
  </tr>
181
  <tr>
182
  <td>authortextweight</td>
183
- <td><?php _e( "Weight of author info font inherit, bold, or normal", 'custom-twitter-feed' ); ?></td>
184
- <td><code>[custom-twitter-feed authortextweight="bold"]</code></td>
185
  </tr>
186
  <tr>
187
  <td>datetextsize</td>
188
- <td><?php _e( "Size of date info font in pixels", 'custom-twitter-feed' ); ?></td>
189
- <td><code>[custom-twitter-feed datetextsize="16"]</code></td>
190
  </tr>
191
  <tr>
192
  <td>datetextweight</td>
193
- <td><?php _e( "Weight of date info font inherit, bold, or normal", 'custom-twitter-feed' ); ?></td>
194
- <td><code>[custom-twitter-feed datetextweight="bold"]</code></td>
195
  </tr>
196
  <tr>
197
  <td>quotedtextsize</td>
198
- <td><?php _e( "Size of quoted author info font in pixels", 'custom-twitter-feed' ); ?></td>
199
- <td><code>[custom-twitter-feed quotedauthorsize="16"]</code></td>
200
  </tr>
201
  <tr>
202
  <td>quotedtextweight</td>
203
- <td><?php _e( "Weight of quoted author info font inherit, bold, or normal", 'custom-twitter-feed' ); ?></td>
204
- <td><code>[custom-twitter-feed quotedauthorweight="bold"]</code></td>
205
  </tr>
206
  <tr>
207
  <td>textcolor</td>
208
- <td><?php _e( "Color of the text. Any color hex code", 'custom-twitter-feed' ); ?></td>
209
- <td><code>[custom-twitter-feed textcolor="333"]</code></td>
210
  </tr>
211
  <tr>
212
  <td>linktextcolor</td>
213
- <td><?php _e( "Color of the links inside the tweet text. Any color hex code", 'custom-twitter-feed' ); ?></td>
214
- <td><code>[custom-twitter-feed linktextcolor="00f"]</code></td>
215
  </tr>
216
  <tr>
217
  <td>iconsize</td>
218
- <td><?php _e( "Size of the icons in pixels", 'custom-twitter-feed' ); ?></td>
219
- <td><code>[custom-twitter-feed iconsize="16"]</code></td>
220
  </tr>
221
  <tr>
222
  <td>iconcolor</td>
223
- <td><?php _e( "Color of the icons. Any color hex code", 'custom-twitter-feed' ); ?></td>
224
- <td><code>[custom-twitter-feed iconcolor="e00"]</code></td>
225
  </tr>
226
- <tr class="ctf_table_header"><td colspan=3><?php _e("\"Load More\" Button Options", 'custom-twitter-feed' ); ?></td></tr>
227
  <tr>
228
  <td>buttoncolor</td>
229
- <td><?php _e( "Color of the background of the button. Any color hex code", 'custom-twitter-feed' ); ?></td>
230
- <td><code>[custom-twitter-feed buttoncolor="00e"]</code></td>
231
  </tr>
232
  <tr>
233
  <td>buttontextcolor</td>
234
- <td><?php _e( "Color of the text of the button. Any color hex code", 'custom-twitter-feed' ); ?></td>
235
- <td><code>[custom-twitter-feed buttoncolor="333"]</code></td>
236
  </tr>
237
  <tr>
238
  <td>buttontext</td>
239
- <td><?php _e( "Custom text inside the button", 'custom-twitter-feed' ); ?></td>
240
- <td><code>[custom-twitter-feed buttontext="More..."]</code></td>
241
  </tr>
242
 
243
 
244
  </tbody>
245
  </table>
246
- <p><i class="fa fa-question-circle" aria-hidden="true"></i>&nbsp; <?php _e('Need help? <a href="?page=custom-twitter-feed&tab=support">Get Support</a>.'); ?></p>
1
  <?php ?>
2
 
3
+ <h3><?php _e( 'Display your Feed', 'custom-twitter-feeds' ); ?></h3>
4
+ <p><?php _e( "Copy and paste the following shortcode directly into the page, post or widget where you'd like the feed to show up:", 'custom-twitter-feeds' ); ?></p>
5
+ <input type="text" value="[custom-twitter-feeds]" size="20" readonly="readonly" style="text-align: center;" onclick="this.focus();this.select()" title="<?php _e( 'To copy, click the field then press Ctrl + C (PC) or Cmd + C (Mac).', 'custom-twitter-feeds' ); ?>" />
6
 
7
+ <h3 style="padding-top: 10px;"><?php _e( 'Multiple Feeds', 'custom-twitter-feeds' ); ?></h3>
8
+ <p><?php _e( "If you'd like to display multiple feeds then you can set different settings directly in the shortcode like so:", 'custom-twitter-feeds' ); ?>
9
+ </br><code>[custom-twitter-feeds screenname=gopro num=9]</code></p>
10
+ <p><?php _e( "You can display as many different feeds as you like, on either the same page or on different pages, by just using the shortcode options below. For example:", 'custom-twitter-feeds' ); ?><br />
11
+ <code>[custom-twitter-feeds]</code><br />
12
+ <code>[custom-twitter-feeds screenname="ANOTHER_SCREEN_NAME"]</code><br />
13
+ <code>[custom-twitter-feeds hashtag="#YOUR_HASHTAG" num=4 showfollow=false]</code>
14
  </p>
15
+ <p><?php _e( "See the table below for a full list of available shortcode options:", 'custom-twitter-feeds' ); ?></p>
16
 
17
+ <!-- <p><span class="ctf_table_key"></span><?php _e( 'Pro version only', 'custom-twitter-feeds' ); ?></p> -->
18
 
19
  <table class="ctf_shortcode_table">
20
  <tbody>
21
  <tr valign="top">
22
+ <th scope="row"><?php _e( 'Shortcode option', 'custom-twitter-feeds' ); ?></th>
23
+ <th scope="row"><?php _e( 'Description', 'custom-twitter-feeds' ); ?></th>
24
+ <th scope="row"><?php _e( 'Example', 'custom-twitter-feeds' ); ?></th>
25
  </tr>
26
 
27
+ <tr class="ctf_table_header"><td colspan=3><?php _e( "Configure Options", 'custom-twitter-feeds' ); ?></td></tr>
28
  <tr>
29
  <td>screenname</td>
30
+ <td><?php _e( 'A user account name/Twitter handle. This will generate a user timeline feed', 'custom-twitter-feeds' ); ?></td>
31
+ <td><code>[custom-twitter-feeds screenname="gopro"]</code></td>
32
  </tr>
33
  <tr>
34
  <td>hashtag</td>
35
+ <td><?php _e( 'Any hashtag. This will generate a hashtag feed', 'custom-twitter-feeds' ); ?></td>
36
+ <td><code>[custom-twitter-feeds hashtag="#awesome"]</code></td>
37
  </tr>
38
  <tr>
39
  <td>home</td>
40
+ <td><?php _e( 'A home timeline will automatically use the account attached to your access token credentials', 'custom-twitter-feeds' ); ?></td>
41
+ <td><code>[custom-twitter-feeds home=true]</code></td>
42
  </tr>
43
  <!-- <tr class="ctf_pro">
44
  <td>type</td>
45
+ <td><?php _e( "Display tweets from multiple user accounts/Twitter handles<br />Display tweets from multiple hashtags/search terms<br />Display tweets that \"@\" mention your account", 'custom-twitter-feeds' ); ?></td>
46
+ <td><code>[custom-twitter-feeds screenname="gopro, NBA"]</code><br /><code>[custom-twitter-feeds search="#awesome+@nba"]</code><br/><code>[custom-twitter-feeds mentions=true]</code></td>
47
  </tr>
48
  <tr class="ctf_pro">
49
  <td>user</td>
50
+ <td><?php _e( 'A user account name/Twitter handle, separated by commas', 'custom-twitter-feeds' ); ?></td>
51
+ <td><code>[custom-twitter-feeds screenname="gopro, NBA"]</code></td>
52
  </tr>
53
  <tr class="ctf_pro">
54
  <td>searchterm</td>
55
+ <td><?php _e( 'Any search term or terms. Separate multiple terms by "+".', 'custom-twitter-feeds' ); ?></td>
56
+ <td><code>[custom-twitter-feeds search="#awesome+@nba"]</code></td>
57
  </tr>
58
  <tr class="ctf_pro">
59
  <td>(no argument needed)</td>
60
+ <td><?php _e( 'A mentions timeline will automatically use the account attached to your access token credentials', 'custom-twitter-feeds' ); ?></td>
61
+ <td><code>[custom-twitter-feeds mentions=true]</code></td>
62
  </tr> -->
63
  <tr>
64
  <td>num</td>
65
+ <td><?php _e( 'Number of Tweets to display', 'custom-twitter-feeds' ); ?></td>
66
+ <td><code>[custom-twitter-feeds num=20]</code></td>
67
  </tr>
68
 
69
+ <tr class="ctf_table_header"><td colspan=3><?php _e("Customize Options", 'custom-twitter-feeds' ); ?></td></tr>
70
  <tr>
71
  <td>class</td>
72
+ <td><?php _e( "A custom CSS class added to the feed", 'custom-twitter-feeds' ); ?></td>
73
+ <td><code>[custom-twitter-feeds class="my-class"]</code></td>
74
  </tr>
75
  <tr>
76
  <td>headertext</td>
77
+ <td><?php _e( "Custom text for the header", 'custom-twitter-feeds' ); ?></td>
78
+ <td><code>[custom-twitter-feeds headertext="My Tweets"]</code></td>
79
  </tr>
80
+ <tr class="ctf_table_header"><td colspan=3><?php _e("Show/Hide Options", 'custom-twitter-feeds' ); ?></td></tr>
81
  <tr>
82
  <td>showheader</td>
83
+ <td><?php _e( "Include a header for this feed", 'custom-twitter-feeds' ); ?></td>
84
+ <td><code>[custom-twitter-feeds showheader=true]</code></td>
85
  </tr>
86
  <tr>
87
  <td>include</td>
88
+ <td><?php _e( "Parts of the Tweet to include in the feed", 'custom-twitter-feeds' ); ?></td>
89
+ <td><code>[custom-twitter-feeds include="author,date,text,avatar"]</code></td>
90
  </tr>
91
  <tr>
92
  <td>exclude</td>
93
+ <td><?php _e( "Parts of the Tweet to exclude in the feed", 'custom-twitter-feeds' ); ?></td>
94
+ <td><code>[custom-twitter-feeds exclude="retweeter,actions,linkbox,twitterlink"]</code></td>
95
  </tr>
96
  <tr>
97
  <td>creditctf</td>
98
+ <td><?php _e( "Include a credit link to Custom Twitter Feeds homepage at the bottom of the feed", 'custom-twitter-feeds' ); ?></td>
99
+ <td><code>[custom-twitter-feeds creditctf=true]</code></td>
100
  </tr>
101
  <tr>
102
  <td>showbutton</td>
103
+ <td><?php _e( "Show the button that loads more tweets", 'custom-twitter-feeds' ); ?></td>
104
+ <td><code>[custom-twitter-feeds showbutton=false]</code></td>
105
  </tr>
106
+ <tr class="ctf_table_header"><td colspan=3><?php _e("Date Options", 'custom-twitter-feeds' ); ?></td></tr>
107
  <tr>
108
  <td>dateformat</td>
109
+ <td><?php _e( "Number of one of the default date formats", 'custom-twitter-feeds' ); ?></td>
110
+ <td><code>[custom-twitter-feeds dateformat=3]</code></td>
111
  </tr>
112
  <tr>
113
  <td>datecustom</td>
114
+ <td><?php _e( "Manually entered custom date format", 'custom-twitter-feeds' ); ?></td>
115
+ <td><code>[custom-twitter-feeds datecustom="D M jS, Y"]</code></td>
116
  </tr>
117
  <tr>
118
  <td>mtime</td>
119
+ <td><?php _e( "Translation for \"m\" time unit (English minute)", 'custom-twitter-feeds' ); ?></td>
120
+ <td><code>[custom-twitter-feeds mtime="M"]</code></td>
121
  </tr>
122
  <tr>
123
  <td>htime</td>
124
+ <td><?php _e( "Translation for \"h\" time unit (English hour)", 'custom-twitter-feeds' ); ?></td>
125
+ <td><code>[custom-twitter-feeds htime="S"]</code></td>
126
  </tr>
127
  <tr>
128
  <td>nowtime</td>
129
+ <td><?php _e( "Translation for English \"now\"", 'custom-twitter-feeds' ); ?></td>
130
+ <td><code>[custom-twitter-feeds nowtime="jetzt"]</code></td>
131
  </tr>
132
+ <tr class="ctf_table_header"><td colspan=3><?php _e("Link Options", 'custom-twitter-feeds' ); ?></td></tr>
133
  <tr>
134
  <td>disablelinks</td>
135
+ <td><?php _e( "Disable the links in the text of the tweet", 'custom-twitter-feeds' ); ?></td>
136
+ <td><code>[custom-twitter-feeds disablelinks=false]</code></td>
137
  </tr>
138
  <tr>
139
  <td>linktexttotwitter</td>
140
+ <td><?php _e( "Link the tweet text to Twitter", 'custom-twitter-feeds' ); ?></td>
141
+ <td><code>[custom-twitter-feeds linktexttotwitter=false]</code></td>
142
  </tr>
143
  <tr>
144
  <td>twitterlinktext</td>
145
+ <td><?php _e( "Custom text for the Twitter link", 'custom-twitter-feeds' ); ?></td>
146
+ <td><code>[custom-twitter-feeds twitterlinktext="view on Twitter"]</code></td>
147
  </tr>
148
  <tr>
149
  <td>multiplier</td>
150
+ <td><?php _e( 'A multiplying factor 1-3 to help with tweet filtering', 'custom-twitter-feeds' ); ?></td>
151
+ <td><code>[custom-twitter-feeds multiplier=2.25]</code></td>
152
  </tr>
153
 
154
+ <tr class="ctf_table_header"><td colspan=3><?php _e("Style Options", 'custom-twitter-feeds' ); ?></td></tr>
155
  <tr>
156
  <td>width</td>
157
+ <td><?php _e( "The width of your feed. Any number with a unit like \"px\" or \"%\".", 'custom-twitter-feeds' ); ?></td>
158
+ <td><code>[custom-twitter-feeds width=400px]</code></td>
159
  </tr>
160
  <tr>
161
  <td>height</td>
162
+ <td><?php _e( "The height of your feed. Any number with a unit like \"px\" or \"em\".", 'custom-twitter-feeds' ); ?></td>
163
+ <td><code>[custom-twitter-feeds height=500px]</code></td>
164
  </tr>
165
  <tr>
166
  <td>bgcolor</td>
167
+ <td><?php _e( "Background color for the feed. Any hex color code", 'custom-twitter-feeds' ); ?></td>
168
+ <td><code>[custom-twitter-feeds bgcolor="eee"]</code></td>
169
  </tr>
170
  <tr>
171
  <td>tweetbgcolor</td>
172
+ <td><?php _e( "Background color for each tweet. Any hex color code", 'custom-twitter-feeds' ); ?></td>
173
+ <td><code>[custom-twitter-feeds tweetbgcolor="ddd"]</code></td>
174
  </tr>
175
+ <tr class="ctf_table_header"><td colspan=3><?php _e("Typography Options", 'custom-twitter-feeds' ); ?></td></tr>
176
  <tr>
177
  <td>authortextsize</td>
178
+ <td><?php _e( "Size of author info font in pixels", 'custom-twitter-feeds' ); ?></td>
179
+ <td><code>[custom-twitter-feeds authortextsize="16"]</code></td>
180
  </tr>
181
  <tr>
182
  <td>authortextweight</td>
183
+ <td><?php _e( "Weight of author info font inherit, bold, or normal", 'custom-twitter-feeds' ); ?></td>
184
+ <td><code>[custom-twitter-feeds authortextweight="bold"]</code></td>
185
  </tr>
186
  <tr>
187
  <td>datetextsize</td>
188
+ <td><?php _e( "Size of date info font in pixels", 'custom-twitter-feeds' ); ?></td>
189
+ <td><code>[custom-twitter-feeds datetextsize="16"]</code></td>
190
  </tr>
191
  <tr>
192
  <td>datetextweight</td>
193
+ <td><?php _e( "Weight of date info font inherit, bold, or normal", 'custom-twitter-feeds' ); ?></td>
194
+ <td><code>[custom-twitter-feeds datetextweight="bold"]</code></td>
195
  </tr>
196
  <tr>
197
  <td>quotedtextsize</td>
198
+ <td><?php _e( "Size of quoted author info font in pixels", 'custom-twitter-feeds' ); ?></td>
199
+ <td><code>[custom-twitter-feeds quotedauthorsize="16"]</code></td>
200
  </tr>
201
  <tr>
202
  <td>quotedtextweight</td>
203
+ <td><?php _e( "Weight of quoted author info font inherit, bold, or normal", 'custom-twitter-feeds' ); ?></td>
204
+ <td><code>[custom-twitter-feeds quotedauthorweight="bold"]</code></td>
205
  </tr>
206
  <tr>
207
  <td>textcolor</td>
208
+ <td><?php _e( "Color of the text. Any color hex code", 'custom-twitter-feeds' ); ?></td>
209
+ <td><code>[custom-twitter-feeds textcolor="333"]</code></td>
210
  </tr>
211
  <tr>
212
  <td>linktextcolor</td>
213
+ <td><?php _e( "Color of the links inside the tweet text. Any color hex code", 'custom-twitter-feeds' ); ?></td>
214
+ <td><code>[custom-twitter-feeds linktextcolor="00f"]</code></td>
215
  </tr>
216
  <tr>
217
  <td>iconsize</td>
218
+ <td><?php _e( "Size of the icons in pixels", 'custom-twitter-feeds' ); ?></td>
219
+ <td><code>[custom-twitter-feeds iconsize="16"]</code></td>
220
  </tr>
221
  <tr>
222
  <td>iconcolor</td>
223
+ <td><?php _e( "Color of the icons. Any color hex code", 'custom-twitter-feeds' ); ?></td>
224
+ <td><code>[custom-twitter-feeds iconcolor="e00"]</code></td>
225
  </tr>
226
+ <tr class="ctf_table_header"><td colspan=3><?php _e("\"Load More\" Button Options", 'custom-twitter-feeds' ); ?></td></tr>
227
  <tr>
228
  <td>buttoncolor</td>
229
+ <td><?php _e( "Color of the background of the button. Any color hex code", 'custom-twitter-feeds' ); ?></td>
230
+ <td><code>[custom-twitter-feeds buttoncolor="00e"]</code></td>
231
  </tr>
232
  <tr>
233
  <td>buttontextcolor</td>
234
+ <td><?php _e( "Color of the text of the button. Any color hex code", 'custom-twitter-feeds' ); ?></td>
235
+ <td><code>[custom-twitter-feeds buttoncolor="333"]</code></td>
236
  </tr>
237
  <tr>
238
  <td>buttontext</td>
239
+ <td><?php _e( "Custom text inside the button", 'custom-twitter-feeds' ); ?></td>
240
+ <td><code>[custom-twitter-feeds buttontext="More..."]</code></td>
241
  </tr>
242
 
243
 
244
  </tbody>
245
  </table>
246
+ <p><i class="fa fa-question-circle" aria-hidden="true"></i>&nbsp; <?php _e('Need help? <a href="?page=custom-twitter-feeds&tab=support">Get Support</a>.'); ?></p>
views/admin/main.php CHANGED
@@ -1,5 +1,5 @@
1
  <div id="ctf-admin" class="wrap">
2
- <h1>Custom Twitter Feed</h1>
3
  <?php
4
  // this controls which view is included based on the selected tab
5
  $tab = isset( $_GET["tab"] ) ? $_GET["tab"] : '';
@@ -8,11 +8,11 @@
8
 
9
  <!-- Display the tabs along with styling for the 'active' tab -->
10
  <h2 class="nav-tab-wrapper">
11
- <a href="admin.php?page=custom-twitter-feed&tab=configure" class="nav-tab <?php if ( $active_tab == 'configure' ){ echo 'nav-tab-active'; } ?>"><?php _e( '1. Configure', 'ctf' ); ?></a>
12
- <a href="admin.php?page=custom-twitter-feed&tab=customize" class="nav-tab <?php if ( $active_tab == 'customize' ){ echo 'nav-tab-active'; } ?>"><?php _e( '2. Customize', 'ctf' ); ?></a>
13
- <a href="admin.php?page=custom-twitter-feed&tab=style" class="nav-tab <?php if ( $active_tab == 'style' ){ echo 'nav-tab-active'; } ?>"><?php _e( '3. Style', 'ctf' ); ?></a>
14
- <a href="admin.php?page=custom-twitter-feed&tab=display" class="nav-tab <?php if ( $active_tab == 'display' ){ echo 'nav-tab-active'; } ?>"><?php _e( '4. Display Your Feed', 'ctf' ); ?></a>
15
- <a href="admin.php?page=custom-twitter-feed&tab=support" class="nav-tab <?php if ( $active_tab == 'support' ){ echo 'nav-tab-active'; } ?>"><?php _e( 'Support', 'ctf' ); ?></a>
16
  </h2>
17
  <?php
18
 
@@ -31,17 +31,17 @@
31
  }
32
  ?>
33
 
34
- <p><i class="fa fa-life-ring" aria-hidden="true"></i>&nbsp; <?php _e('Need help setting up the plugin? Check out our <a href="https://smashballoon.com/custom-twitter-feed/free/" target="_blank">setup directions</a>', 'custom-twitter-feed'); ?></p>
35
 
36
  <div class="ctf-quick-start">
37
- <h3><i class="fa fa-rocket" aria-hidden="true"></i>&nbsp; <?php _e( 'Display your feed', 'custom-twitter-feed'); ?></h3>
38
- <p><?php _e( "Copy and paste this shortcode directly into the page, post or widget where you'd like to display the feed:", "custom-twitter-feed" ); ?>
39
- <input type="text" value="[custom-twitter-feed]" size="18" readonly="readonly" style="text-align: center;" onclick="this.focus();this.select()" title="<?php _e( 'To copy, click the field then press Ctrl + C (PC) or Cmd + C (Mac).', 'custom-twitter-feed' ); ?>" /></p>
40
- <p><?php _e( "Find out how to display <a href='?page=custom-twitter-feed&tab=display'>multiple feeds</a>.", "custom-twitter-feed" ); ?></p>
41
  </div>
42
 
43
- <a href="https://smashballoon.com/custom-twitter-feed/" target="_blank" class="ctf-pro-notice">
44
- <img src="<?php echo plugins_url( '../../img/pro-notice.png' , __FILE__ ) ?>" alt="The Custom Twitter Feed Pro" />
45
  </a>
46
 
47
  </div>
1
  <div id="ctf-admin" class="wrap">
2
+ <h1>Custom Twitter Feeds</h1>
3
  <?php
4
  // this controls which view is included based on the selected tab
5
  $tab = isset( $_GET["tab"] ) ? $_GET["tab"] : '';
8
 
9
  <!-- Display the tabs along with styling for the 'active' tab -->
10
  <h2 class="nav-tab-wrapper">
11
+ <a href="admin.php?page=custom-twitter-feeds&tab=configure" class="nav-tab <?php if ( $active_tab == 'configure' ){ echo 'nav-tab-active'; } ?>"><?php _e( '1. Configure', 'ctf' ); ?></a>
12
+ <a href="admin.php?page=custom-twitter-feeds&tab=customize" class="nav-tab <?php if ( $active_tab == 'customize' ){ echo 'nav-tab-active'; } ?>"><?php _e( '2. Customize', 'ctf' ); ?></a>
13
+ <a href="admin.php?page=custom-twitter-feeds&tab=style" class="nav-tab <?php if ( $active_tab == 'style' ){ echo 'nav-tab-active'; } ?>"><?php _e( '3. Style', 'ctf' ); ?></a>
14
+ <a href="admin.php?page=custom-twitter-feeds&tab=display" class="nav-tab <?php if ( $active_tab == 'display' ){ echo 'nav-tab-active'; } ?>"><?php _e( '4. Display Your Feed', 'ctf' ); ?></a>
15
+ <a href="admin.php?page=custom-twitter-feeds&tab=support" class="nav-tab <?php if ( $active_tab == 'support' ){ echo 'nav-tab-active'; } ?>"><?php _e( 'Support', 'ctf' ); ?></a>
16
  </h2>
17
  <?php
18
 
31
  }
32
  ?>
33
 
34
+ <p><i class="fa fa-life-ring" aria-hidden="true"></i>&nbsp; <?php _e('Need help setting up the plugin? Check out our <a href="https://smashballoon.com/custom-twitter-feeds/free/" target="_blank">setup directions</a>', 'custom-twitter-feeds'); ?></p>
35
 
36
  <div class="ctf-quick-start">
37
+ <h3><i class="fa fa-rocket" aria-hidden="true"></i>&nbsp; <?php _e( 'Display your feed', 'custom-twitter-feeds'); ?></h3>
38
+ <p><?php _e( "Copy and paste this shortcode directly into the page, post or widget where you'd like to display the feed:", "custom-twitter-feeds" ); ?>
39
+ <input type="text" value="[custom-twitter-feeds]" size="18" readonly="readonly" style="text-align: center;" onclick="this.focus();this.select()" title="<?php _e( 'To copy, click the field then press Ctrl + C (PC) or Cmd + C (Mac).', 'custom-twitter-feeds' ); ?>" /></p>
40
+ <p><?php _e( "Find out how to display <a href='?page=custom-twitter-feeds&tab=display'>multiple feeds</a>.", "custom-twitter-feeds" ); ?></p>
41
  </div>
42
 
43
+ <a href="https://smashballoon.com/custom-twitter-feeds/" target="_blank" class="ctf-pro-notice">
44
+ <img src="<?php echo plugins_url( '../../img/pro-notice.png' , __FILE__ ) ?>" alt="Custom Twitter Feeds Pro" />
45
  </a>
46
 
47
  </div>
views/admin/style.php CHANGED
@@ -21,4 +21,4 @@ settings_errors(); ?>
21
  <a id="load"></a>
22
  <?php do_settings_sections( 'ctf_style_load' ); // matches the section name ?>
23
  </form>
24
- <p><i class="fa fa-chevron-circle-right" aria-hidden="true"></i>&nbsp; <?php _e('Next Step: <a href="?page=custom-twitter-feed&tab=display">Display your Feed</a>'); ?></p>
21
  <a id="load"></a>
22
  <?php do_settings_sections( 'ctf_style_load' ); // matches the section name ?>
23
  </form>
24
+ <p><i class="fa fa-chevron-circle-right" aria-hidden="true"></i>&nbsp; <?php _e('Next Step: <a href="?page=custom-twitter-feeds&tab=display">Display your Feed</a>'); ?></p>
views/admin/support.php CHANGED
@@ -1,15 +1,15 @@
1
- <h3><?php _e( 'Need help?', 'custom-twitter-feed' ); ?></h3>
2
 
3
- <p><i class="fa fa-life-ring" aria-hidden="true"></i>&nbsp; <?php _e( 'Check out our ', 'custom-twitter-feed'); ?><a href="https://smashballoon.com/custom-twitter-feed/free/" target="_blank"><?php _e( 'setup directions', 'custom-twitter-feed' ); ?></a> <?php _e( 'for a step-by-step guide on how to setup and use the plugin', 'custom-twitter-feed' ); ?>.</p>
4
 
5
- <p><i class="fa fa-envelope" aria-hidden="true"></i>&nbsp; <?php _e( 'Have a problem? Submit a ', 'custom-twitter-feed' ); ?><a href="https://smashballoon.com/custom-twitter-feed/support/" target="_blank"><?php _e( 'support ticket', 'custom-twitter-feed' ); ?></a> <?php _e( 'on our website', 'custom-twitter-feed' ); ?>. <?php _e( 'Please include your <b>System Info</b> below with all support requests.', 'custom-twitter-feed' ); ?></p>
6
 
7
  <br />
8
- <h3><?php _e('System Info', 'custom-twitter-feed' ); ?> &nbsp; <i style="color: #666; font-size: 11px; font-weight: normal;"><?php _e( 'Click the text below to select all', 'custom-twitter-feed' ); ?></i></h3>
9
 
10
  <textarea readonly="readonly" onclick="this.focus();this.select()" title="To copy, click the field then press Ctrl + C (PC) or Cmd + C (Mac)." style="width: 70%; height: 500px; white-space: pre; font-family: Menlo,Monaco,monospace;">
11
  ## SITE/SERVER INFO: ##
12
- Plugin Version: <?php echo CTF_TITLE . ' v' . CTFVER . "\n"; ?>
13
  Site URL: <?php echo site_url() . "\n"; ?>
14
  Home URL: <?php echo home_url() . "\n"; ?>
15
  WordPress Version: <?php echo get_bloginfo( 'version' ) . "\n"; ?>
1
+ <h3><?php _e( 'Need help?', 'custom-twitter-feeds' ); ?></h3>
2
 
3
+ <p><i class="fa fa-life-ring" aria-hidden="true"></i>&nbsp; <?php _e( 'Check out our ', 'custom-twitter-feeds'); ?><a href="https://smashballoon.com/custom-twitter-feeds/free/" target="_blank"><?php _e( 'setup directions', 'custom-twitter-feeds' ); ?></a> <?php _e( 'for a step-by-step guide on how to setup and use the plugin', 'custom-twitter-feeds' ); ?>.</p>
4
 
5
+ <p><i class="fa fa-envelope" aria-hidden="true"></i>&nbsp; <?php _e( 'Have a problem? Submit a ', 'custom-twitter-feeds' ); ?><a href="https://smashballoon.com/custom-twitter-feeds/support/" target="_blank"><?php _e( 'support ticket', 'custom-twitter-feeds' ); ?></a> <?php _e( 'on our website', 'custom-twitter-feeds' ); ?>. <?php _e( 'Please include your <b>System Info</b> below with all support requests.', 'custom-twitter-feeds' ); ?></p>
6
 
7
  <br />
8
+ <h3><?php _e('System Info', 'custom-twitter-feeds' ); ?> &nbsp; <i style="color: #666; font-size: 11px; font-weight: normal;"><?php _e( 'Click the text below to select all', 'custom-twitter-feeds' ); ?></i></h3>
9
 
10
  <textarea readonly="readonly" onclick="this.focus();this.select()" title="To copy, click the field then press Ctrl + C (PC) or Cmd + C (Mac)." style="width: 70%; height: 500px; white-space: pre; font-family: Menlo,Monaco,monospace;">
11
  ## SITE/SERVER INFO: ##
12
+ Plugin Version: <?php echo CTF_TITLE . ' v' . CTF_VERSION . "\n"; ?>
13
  Site URL: <?php echo site_url() . "\n"; ?>
14
  Home URL: <?php echo home_url() . "\n"; ?>
15
  WordPress Version: <?php echo get_bloginfo( 'version' ) . "\n"; ?>