=')) { return; } } deactivate_plugins(basename(__FILE__)); // Deactivate ourself wp_die("The base SFC plugin must be activated before this plugin will run."); } register_activation_hook(__FILE__, 'sfc_fan_box_activation_check'); function get_sfc_fanbox($args='') { $options = get_option('sfc_options'); $args = wp_parse_args($args, array( 'stream' => 1, 'connections' => 10, 'width' => 200, 'height' => 0, 'logobar' => 1 )); extract($args); if ($options['fanpage']) $id = $options['fanpage']; else $id = $options['appid']; $retvar = ' 1, 'connections' => 10, 'width' => 200, 'height' => 0, 'logobar' => 1, ), $atts); return get_sfc_fanbox($args); } add_shortcode('fb-fanbox', 'sfc_fanbox_shortcode'); class SFC_Fan_Box_Widget extends WP_Widget { function SFC_Fan_Box_Widget() { $widget_ops = array('classname' => 'widget_sfc-fanbox', 'description' => 'Facebook Fan Box'); $this->WP_Widget('sfc-fanbox', 'Facebook Fan Box (SFC)', $widget_ops); } function widget($args, $instance) { extract( $args ); $title = apply_filters('widget_title', $instance['title']); $instance['stream'] = isset($instance['stream']) ? $instance['stream'] : 1; $instance['logobar'] = isset($instance['logobar']) ? $instance['logobar'] : 1; $instance['connections'] = intval($instance['connections']); $instance['width'] = intval($instance['width']); $instance['height'] = intval($instance['height']); ?> '', 'connections' => '0', 'logobar'=> 0, 'stream' => 0, 'width'=>200, 'height'=>0) ); $instance['title'] = strip_tags($new_instance['title']); $instance['connections'] = intval($new_instance['connections']); $instance['width'] = intval($new_instance['width']); if ($instance['width'] < 200) $instance['width'] = 200; $instance['height'] = intval($new_instance['height']); $instance['stream'] = $new_instance['stream'] ? 1 : 0; $instance['logobar'] = $new_instance['logobar'] ? 1 : 0; return $instance; } function form($instance) { $instance = wp_parse_args( (array) $instance, array( 'title' => '', 'connections' => '0', 'logobar'=> 0, 'stream' => 0, 'width'=>200, 'height'=>0) ); $title = strip_tags($instance['title']); $connections = intval($instance['connections']); $width = intval($instance['width']); $height = intval($instance['height']); $stream = $instance['stream'] ? true : false; $logobar = $instance['logobar'] ? true : false; ?>

Use this area to add any custom CSS you like to the Facebook Fan Box display.

'; } function sfc_fanbox_css_callback() { $options = get_option('sfc_options'); if (!$options['fanbox_css']) $options['fanbox_css'] = ''; /* good default CSS to use: .connect_widget .connect_widget_facebook_logo_menubar { } .fan_box .full_widget .connect_top { } .fan_box .full_widget .page_stream { } .fan_box .full_widget .connections { } */ ?>