Custom Facebook Feed - Version 1.9.6

Version Description

  • Tweak: Added an HTML wrapper element around the feed
Download this release

Release Info

Developer smashballoon
Plugin Icon 128x128 Custom Facebook Feed
Version 1.9.6
Comparing to
See all releases

Code changes from version 1.9.5 to 1.9.6

README.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: smashballoon
3
Tags: Facebook, Facebook feed, Facebook posts, Facebook wall, Facebook events, Facebook page, Facebook group, Facebook Like box, Customizable Facebook Feed, custom, customizable, seo, responsive, mobile, social
4
Requires at least: 3.0
5
Tested up to: 3.9
6
- Stable tag: 1.9.5
7
License: GPLv2 or later
8
License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
@@ -269,6 +269,9 @@ Credit [iMarketing Factory](http://www.imarketingfactory.com/facebook/ "The Impo
269
9. It's super easy to display your Facebook feed in any page or post
270
271
== Changelog ==
272
= 1.9.5 =
273
* New: Added an option to set a height on the Like box. This allows you to display more faces of your fans if you have that option selected.
274
* Tweak: Added a few stricter CSS styles to help minimize the chance of theme stylesheets distorting post formatting
3
Tags: Facebook, Facebook feed, Facebook posts, Facebook wall, Facebook events, Facebook page, Facebook group, Facebook Like box, Customizable Facebook Feed, custom, customizable, seo, responsive, mobile, social
4
Requires at least: 3.0
5
Tested up to: 3.9
6
+ Stable tag: 1.9.6
7
License: GPLv2 or later
8
License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
269
9. It's super easy to display your Facebook feed in any page or post
270
271
== Changelog ==
272
+ = 1.9.6 =
273
+ * Tweak: Added an HTML wrapper element around the feed
274
+
275
= 1.9.5 =
276
* New: Added an option to set a height on the Like box. This allows you to display more faces of your fans if you have that option selected.
277
* Tweak: Added a few stricter CSS styles to help minimize the chance of theme stylesheets distorting post formatting
css/cff-style.css CHANGED
@@ -1,7 +1,13 @@
1
/**************/
2
/*** LAYOUT ***/
3
/**************/
4
- /* Feed container */
5
#cff {
6
float: left;
7
width: 100%;
@@ -11,11 +17,6 @@
11
-moz-box-sizing: border-box;
12
box-sizing: border-box;
13
}
14
- #cff:after{
15
- content: "";
16
- display: table;
17
- clear: both;
18
- }
19
/* Individual post item */
20
#cff .cff-item{
21
float: left;
1
/**************/
2
/*** LAYOUT ***/
3
/**************/
4
+ /* Feed wrapper */
5
+ .cff-wrapper:after{
6
+ content: "";
7
+ display: table;
8
+ clear: both;
9
+ }
10
+ /* Posts container */
11
#cff {
12
float: left;
13
width: 100%;
17
-moz-box-sizing: border-box;
18
box-sizing: border-box;
19
}
20
/* Individual post item */
21
#cff .cff-item{
22
float: left;
custom-facebook-feed-admin.php CHANGED
@@ -114,7 +114,7 @@ function cff_settings_page() {
114
?>
115
<h2 class="nav-tab-wrapper">
116
<a href="?page=cff-top&amp;tab=configuration" class="nav-tab <?php echo $active_tab == 'configuration' ? 'nav-tab-active' : ''; ?>"><?php _e('Configuration'); ?></a>
117
- <a href="?page=cff-style" class="nav-tab <?php echo $active_tab == 'support' ? 'nav-tab-active' : ''; ?>"><?php _e('Customize'); ?></a>
118
<a href="?page=cff-top&amp;tab=support" class="nav-tab <?php echo $active_tab == 'support' ? 'nav-tab-active' : ''; ?>"><?php _e('Support'); ?></a>
119
</h2>
120
@@ -319,6 +319,9 @@ function cff_settings_page() {
319
<p>[custom-facebook-feed <b><span style='color: green;'>id=some-other-page-id num=3 height=500px</span></b>]</p>
320
<p><a href="http://smashballoon.com/custom-facebook-feed/docs/shortcodes/" target="_blank"><?php _e('See a full list of shortcode options'); ?></a></p>
321
322
<?php } //End config tab ?>
323
324
@@ -365,8 +368,18 @@ function cff_settings_page() {
365
366
<?php } ?>
367
368
-
369
- <?php
370
371
//Defaults need to be here on the Settings page so that they're saved when the initial settings are saved
372
$defaults = array(
@@ -519,23 +532,6 @@ function cff_settings_page() {
519
$options = wp_parse_args(get_option('cff_style_settings'), $defaults);
520
add_option( 'cff_style_settings', $options );
521
522
- ?>
523
-
524
-
525
- <?php
526
- } //End Settings_Page
527
- //Create Style page
528
- function cff_style_page() {
529
- //Declare variables for fields
530
- $style_hidden_field_name = 'cff_style_submit_hidden';
531
- $style_general_hidden_field_name = 'cff_style_general_submit_hidden';
532
- $style_post_layout_hidden_field_name = 'cff_style_post_layout_submit_hidden';
533
- $style_typography_hidden_field_name = 'cff_style_typography_submit_hidden';
534
- $style_misc_hidden_field_name = 'cff_style_misc_submit_hidden';
535
- $style_custom_text_hidden_field_name = 'cff_style_custom_text_submit_hidden';
536
-
537
- $options = get_option('cff_style_settings');
538
-
539
//Set the page variables
540
//Post types
541
$cff_show_links_type = $options[ 'cff_show_links_type' ];
114
?>
115
<h2 class="nav-tab-wrapper">
116
<a href="?page=cff-top&amp;tab=configuration" class="nav-tab <?php echo $active_tab == 'configuration' ? 'nav-tab-active' : ''; ?>"><?php _e('Configuration'); ?></a>
117
+ <a href="?page=cff-style" class="nav-tab <?php echo $active_tab == 'customize' ? 'nav-tab-active' : ''; ?>"><?php _e('Customize'); ?></a>
118
<a href="?page=cff-top&amp;tab=support" class="nav-tab <?php echo $active_tab == 'support' ? 'nav-tab-active' : ''; ?>"><?php _e('Support'); ?></a>
119
</h2>
120
319
<p>[custom-facebook-feed <b><span style='color: green;'>id=some-other-page-id num=3 height=500px</span></b>]</p>
320
<p><a href="http://smashballoon.com/custom-facebook-feed/docs/shortcodes/" target="_blank"><?php _e('See a full list of shortcode options'); ?></a></p>
321
322
+ <br />
323
+ <a href="http://smashballoon.com/custom-facebook-feed/demo" target="_blank"><img src="<?php echo plugins_url( 'img/pro.png' , __FILE__ ) ?>" /></a>
324
+
325
<?php } //End config tab ?>
326
327
368
369
<?php } ?>
370
371
+
372
+ <?php
373
+ } //End Settings_Page
374
+ //Create Style page
375
+ function cff_style_page() {
376
+ //Declare variables for fields
377
+ $style_hidden_field_name = 'cff_style_submit_hidden';
378
+ $style_general_hidden_field_name = 'cff_style_general_submit_hidden';
379
+ $style_post_layout_hidden_field_name = 'cff_style_post_layout_submit_hidden';
380
+ $style_typography_hidden_field_name = 'cff_style_typography_submit_hidden';
381
+ $style_misc_hidden_field_name = 'cff_style_misc_submit_hidden';
382
+ $style_custom_text_hidden_field_name = 'cff_style_custom_text_submit_hidden';
383
384
//Defaults need to be here on the Settings page so that they're saved when the initial settings are saved
385
$defaults = array(
532
$options = wp_parse_args(get_option('cff_style_settings'), $defaults);
533
add_option( 'cff_style_settings', $options );
534
535
//Set the page variables
536
//Post types
537
$cff_show_links_type = $options[ 'cff_show_links_type' ];
custom-facebook-feed.php CHANGED
@@ -3,7 +3,7 @@
3
Plugin Name: Custom Facebook Feed
4
Plugin URI: http://smashballoon.com/custom-facebook-feed
5
Description: Add a completely customizable Facebook feed to your WordPress site
6
- Version: 1.9.5
7
Author: Smash Balloon
8
Author URI: http://smashballoon.com/
9
License: GPLv2 or later
@@ -590,6 +590,7 @@ function display_cff($atts) {
590
if ($cff_like_box_position == 'top' && $cff_show_like_box && $cff_like_box_outside) $cff_content .= $like_box;
591
592
//Create CFF container HTML
593
$cff_content .= '<div id="cff" rel="'.$title_limit.'" class="';
594
if( !empty($cff_class) ) $cff_content .= $cff_class . ' ';
595
if ( !empty($cff_feed_height) ) $cff_content .= 'cff-fixed-height ';
@@ -1110,6 +1111,8 @@ function display_cff($atts) {
1110
if( $atts[ 'ajax' ] == 'false' ) $ajax_theme = false;
1111
if ($ajax_theme) $cff_content .= '<script type="text/javascript" src="' . plugins_url( '/js/cff-scripts.js?8' , __FILE__ ) . '"></script>';
1112
1113
//Return our feed HTML to display
1114
return $cff_content;
1115
}
@@ -1517,27 +1520,27 @@ function cff_scripts_method() {
1517
wp_enqueue_script('cffscripts');
1518
}
1519
1520
- // function cff_activate() {
1521
- // $options = get_option('cff_style_settings');
1522
- // $options[ 'cff_show_links_type' ] = true;
1523
- // $options[ 'cff_show_event_type' ] = true;
1524
- // $options[ 'cff_show_video_type' ] = true;
1525
- // $options[ 'cff_show_photos_type' ] = true;
1526
- // $options[ 'cff_show_status_type' ] = true;
1527
- // $options[ 'cff_show_author' ] = true;
1528
- // $options[ 'cff_show_text' ] = true;
1529
- // $options[ 'cff_show_desc' ] = true;
1530
- // $options[ 'cff_show_shared_links' ] = true;
1531
- // $options[ 'cff_show_date' ] = true;
1532
- // $options[ 'cff_show_media' ] = true;
1533
- // $options[ 'cff_show_event_title' ] = true;
1534
- // $options[ 'cff_show_event_details' ] = true;
1535
- // $options[ 'cff_show_meta' ] = true;
1536
- // $options[ 'cff_show_link' ] = true;
1537
- // $options[ 'cff_show_like_box' ] = true;
1538
- // update_option( 'cff_style_settings', $options );
1539
- // }
1540
- // register_activation_hook( __FILE__, 'cff_activate' );
1541
//Uninstall
1542
function cff_uninstall()
1543
{
3
Plugin Name: Custom Facebook Feed
4
Plugin URI: http://smashballoon.com/custom-facebook-feed
5
Description: Add a completely customizable Facebook feed to your WordPress site
6
+ Version: 1.9.6
7
Author: Smash Balloon
8
Author URI: http://smashballoon.com/
9
License: GPLv2 or later
590
if ($cff_like_box_position == 'top' && $cff_show_like_box && $cff_like_box_outside) $cff_content .= $like_box;
591
592
//Create CFF container HTML
593
+ $cff_content .= '<div class="cff-wrapper">';
594
$cff_content .= '<div id="cff" rel="'.$title_limit.'" class="';
595
if( !empty($cff_class) ) $cff_content .= $cff_class . ' ';
596
if ( !empty($cff_feed_height) ) $cff_content .= 'cff-fixed-height ';
1111
if( $atts[ 'ajax' ] == 'false' ) $ajax_theme = false;
1112
if ($ajax_theme) $cff_content .= '<script type="text/javascript" src="' . plugins_url( '/js/cff-scripts.js?8' , __FILE__ ) . '"></script>';
1113
1114
+ $cff_content .= '</div>';
1115
+
1116
//Return our feed HTML to display
1117
return $cff_content;
1118
}
1520
wp_enqueue_script('cffscripts');
1521
}
1522
1523
+ function cff_activate() {
1524
+ $options = get_option('cff_style_settings');
1525
+ $options[ 'cff_show_links_type' ] = true;
1526
+ $options[ 'cff_show_event_type' ] = true;
1527
+ $options[ 'cff_show_video_type' ] = true;
1528
+ $options[ 'cff_show_photos_type' ] = true;
1529
+ $options[ 'cff_show_status_type' ] = true;
1530
+ $options[ 'cff_show_author' ] = true;
1531
+ $options[ 'cff_show_text' ] = true;
1532
+ $options[ 'cff_show_desc' ] = true;
1533
+ $options[ 'cff_show_shared_links' ] = true;
1534
+ $options[ 'cff_show_date' ] = true;
1535
+ $options[ 'cff_show_media' ] = true;
1536
+ $options[ 'cff_show_event_title' ] = true;
1537
+ $options[ 'cff_show_event_details' ] = true;
1538
+ $options[ 'cff_show_meta' ] = true;
1539
+ $options[ 'cff_show_link' ] = true;
1540
+ $options[ 'cff_show_like_box' ] = true;
1541
+ update_option( 'cff_style_settings', $options );
1542
+ }
1543
+ register_activation_hook( __FILE__, 'cff_activate' );
1544
//Uninstall
1545
function cff_uninstall()
1546
{