Usamos cookies para medir audiência e melhorar sua experiência. Você pode aceitar ou recusar a qualquer momento. Veja sobre o iMasters.
Olá, utilizo o plugin Facebook Comments for WordPress e tive um problema quanto à largura do box na página. Tentei mexer no CSS do WordPress mas não resolveu, uso o Tema: Premium News.
Alguém sabe o que pode estar acontecendo?
Gente, sou iniciante mesmo e não tenho experiência nenhuma com qualquer linguagem de programação. Assim como nunca tive blog, seja WP, Bloguer ou algum outro.
Essa agora é a minha primeira experiência! Por isso que conto tanto com a ajuda de vocês.
Vou postar algumas informações a mais pra ver se alguém me da alguma luz.
Folha de estilos (style.css)
/*
Theme Name: Original Premium News
Theme URI: http://www.woothemes.com/
Description: Original Premium News by WooThemes
Version: 2.4.5
Author: WooThemes
Author URI: http://www.woothemes.com/
Copyright: (c) 2009 WooThemes.
License: GNU General Public License v2.0
License URI: http://www.gnu.org/licenses/gpl-2.0.html
*/
/========= SETUP =========/
*{
border: 0;
margin: 0;
padding: 0;
}background: url(images/bgr.gif) #bcbcbc repeat-x top;
color: #000000;
font: 0.8em Arial,Helvetica,Sans-Serif;
}color: #ff7800;
text-decoration: none;
}text-decoration: underline;
}
input,select,textarea{
border: #999999 1px solid;
font-size: 12px;
padding: 2px;
}
select{
padding: 0;
}list-style: none;
}
/========= LAYOUT =========/
#page{
background: #ffffff;
margin: 0 auto;
width: 960px;
}
/--- Main Columns ---/
#columns{
margin: 20px 0 0;
padding: 0 15px 25px;
}
.col1{
float: left;
width: 550px;
}
.col2{
float: right;
width: 350px;
}
/--- Sub Columns ---/
.subcol{
width: 160px;
}
.subcol h2{
color: #607676;
font-size: 14px;
padding: 0 0 10px;
}
/========= HEADER =========/
/- Page Navigation -/
.sub-menu, ul.children { visibility: visible !important; display: block !important; } / Make sure the sub-menus are visible and don't conflict with the Easing jQuery plugin. /
#nav{
background: #000000;
height: 30px;
padding: 4px 0 0;
}
#nav-left {
float:left;
display:inline;
width:570px;
}
#nav-right {
float:right;
display:inline;
width:370px;
}
#nav ul {
position: relative;
height: 26px;
overflow: hidden;
padding-left:10px;
}
#nav ul li {
float: left;
list-style: none;
font-weight:bold;
font-size:14px;
}
#nav ul li.back {
background-color: #333333;
width: 9px;
height: 30px;
z-index: 8;
position: absolute;
}
#nav ul li a {
text-decoration: none;
color: #dddddd;
outline: none;
text-align: center;
top: 6px;
text-transform: uppercase;
letter-spacing: 0;
z-index: 10;
display: block;
float: left;
height: 26px;
position: relative;
overflow: hidden;
margin: auto 15px !important;
margin: auto 7px;
}
#nav ul li a:hover, #nav ul li a:active, #nav ul li a:visited {
border: none;
}
/- Category Navigation -/
.nav2, .nav2 * {
margin:0;
padding:0;
}
.nav2 {
height: 35px;
border-bottom:3px solid #B3B3B3;
font-weight:bold;
font-size:15px;
position:relative;
}
.nav2 ul {
background:#fff; /IE6 needs this/
float: left;
position:relative;
}
.nav2 li {
line-height: 35px;
float: left;
list-style:none;
z-index:999;
}
.nav2 li.current ul {
z-index: 999;
}
.nav2 li.sfHover ul,
ul.nav2 li:hover ul {
z-index: 1000;
background: #B3B3B3;
color: #ffffff;
text-decoration: none;
}
.nav2 li li {
}
.nav2 a {
color: #000000;
display: block;
padding: 0 13px;
}
.nav2 li ul {
left:0;
top:-999em;
position:absolute;
width:960px;
}
.nav2 li ul ul {
left: auto;
top:-999em;
position:absolute;
width:200px;
margin-top: -2px;
}
.nav2 li ul ul li {
line-height: 20px;
padding-bottom: 10px;
}
.nav2 li:hover,
.nav2 li.sfHover,
.nav2 li.current,
.nav2 a:focus, .nav2 a:hover, .nav2 a:active {
color: #FF7800;
text-decoration: none;
background: #B3B3B3;
}border-bottom: none;
}font-weight: bold;
}}
.nav2 li:hover ul, / pure CSS hover is removed below /
body .nav2 li.current ul, / this must be more specific than the .superfish override below /
ul.nav2 li.sfHover ul {
top:2.5em;
}
.nav2 li:hover li ul,
.nav2 li.sfHover li ul {
top:-999em;
}top:2.5em;
}top: -999em;
}
/.nav2 li.sfHover ul { display: block !important; visibility: visible !important; }/
/- Search -/
#search{
background: #333333;
border: 1px solid #b3b3b3;
float: right;
height: 23px;
margin: 0 15px 0 0;
padding: 0 10px 0 0;
width:325px;
}margin-right: 8px;
}background: transparent;
border: 0;
color: #b3b3b3;
float: left;
font-size: 13px;
margin: 2px 0 0;
padding: 2px 2px 2px 10px;
width:288px;
}margin: 3px 0 0 5px;
padding: 0;
width: auto;
}#header{
background: url(images/hl-dot.gif) repeat-x bottom;
height: 92px;
padding: 0 0 2px;
}float: left;
display:inline;
}display: block;
height: 93px;
width: 389px;
}
/- RSS -/
#rss{
float: right;
font-size: 12px;
padding: 16px 15px 0 0;
text-align: right;
width: 285px;
}color: #b3b3b3;
}float: left;
margin: 13px 0 0;
width: 220px;
}margin: 0 0 3px;
padding: 0 0 5px;
}float: right;
}
/========= FEATURED POSTS (FRONT-PAGE) =========/
.featured{
background: #dddddd;
height: 200px;
margin: 0 0 10px;
overflow: hidden;
position:relative;
}
.featured h2{
font-size: 11px;
padding: 10px 0;
}
.featured h3{
font-size: 14px;
padding: 0 0 10px 0;
}
.featured h3 a {
color:#000;
}
.featured h3 a:hover {
color:#FF7800;
}
.featured p {
margin-bottom:10px;
}
.featured-img{
margin: 0 10px 0 0;
width:350px;
height:200px;
float:left;
display:inline;
}
#ribbon{
width:138px;
height:138px;
position:absolute;
right:200px;
top:0;
}
#featured-th{
height: 57px;
margin: 0 0 30px;
}
#featured-th img{
margin: 0;
border:none;
}
#featured-th .idTabs {
list-style:none;
}
#featured-th .idTabs li {
float:left;
display:inline;
margin-right:12px;
}
#featured-th .idTabs li.last {
margin-right:0px !important;
}
.featured-content { margin-left:367px; padding-right:10px;
}
/========= FEATURED VIDEOS (FRONT-PAGE) =========/
#video-frame {
background:#DDD;
float:left;
width:550px;
height:auto;
margin-bottom:30px;
}
.video-left {
float:left;
width:350px !important;
display:inline;
}
.video-left p {
padding:0px !important;
margin:0px !important;
}
.video-left h2 {
display:none;
}
.video-right {
float:right;
width:200px;
display:inline;
padding-top:7px;
}
.video-right h2{
color: #ff7800;
font-size:1.3em;
line-height:1.2em;
font-weight:bold;
padding: 0 0 0 10px !important;
margin:0 !important;
}
.video-right p{
color: #000;
font-size:0.9em;
line-height:0.8em;
font-weight:bold;
padding: 0 0 7px 10px !important;
margin:0 !important;
}
.video-right .idTabs {
border-top:1px solid #FFF;
list-style:none;
margin:5px 0px 0px 0px;
padding:0px;
}
.video-right .idTabs li {
margin:0px;
border-bottom:1px solid #FFF;
background:#DDD;
line-height:10px;
}
.video-right .idTabs li a {
color:#000;
font-weight:bold;
font-family:Tahoma, Arial;
font-size:12px;
text-decoration:none;
display:block;
padding:10px 10px;
}
.video-right .idTabs li a:hover {
background:#C0C0C0 url(images/ico-watch.gif) right center no-repeat !important;
}
.video-right .selected {
background:#C0C0C0 url(images/ico-watch.gif) right center no-repeat !important;
}
/========= BLOG POST STYLING =========/
/=== Small Box Post ===/
.post{
margin: 0;
}font-size: 1em;
padding: 0 0 5px;
}font-size: 1.3em;
}color: #000000;
}padding: 0 0 15px;
}color: #c0c0c0;
}.box{
border-top: 3px solid #c0c0c0;
clear: both;
height: 1%;
margin: 0 0 20px;
padding: 15px 0 20px;
}width: 260px;
}font-size: .85em;
}font-size: 1em;
}font-size: .85em;
}.post-alt{
margin: 0 0 15px 0;
padding-bottom:15px;
background: url(images/hl-dot.gif) repeat-x bottom;
}font-size: 1.1em;
padding: 0 0 5px;
}font-size: 1.4em;
}color: #000000;
}padding: 0 0 15px;
}color: #c0c0c0;
}.continue{
background: url(images/ico-arrow.gif) no-repeat left;
padding: 0 0 0 13px;
font-weight:bold;
}
.comments {
padding-bottom:0px !important;
}background: url(images/ico-comm.gif) no-repeat left;
color: #000000;
padding: 0 0 0 20px;
font-weight:bold;
}background: url(images/ico-arrow2.gif) no-repeat right;
color: #c0c0c0;
font-size: 1.2em;
font-weight: bold;
padding: 0 20px 0 0;
}.navigation {
}color: #c0c0c0;
font-size: 1.2em;
font-weight: bold;
}
.alignleft{
display:inline;
float:left;
}
.alignright{
display:inline;
float:right;
}
/========= ARCHIVE SPECIFIC =========/
#archivebox {
background:#EEE;
padding:10px;
width:530px;
margin-bottom:25px;
}
#archivebox h2 {
font-size:1.5em;
color:#000;
}
#archivebox h2 em{
color:#C0C0C0 !important;
font-style:normal;
}
.archivefeed {
margin-top:5px;
}
.archivefeed a {
background:url(images/ico-arcfeed.gif) center left no-repeat;
padding-left:20px;
color:#000;
font-weight:bold;
}
.arclist{
border-top: 3px solid #c0c0c0;
border-bottom: 3px solid #c0c0c0;
margin: 0 0 15px;
padding: 10px 0 10px;
width: 260px;
}
.arclist h2{
color: #000;
font-size: 18px;
padding: 0 0 10px 0 !important;
}
.arclist ul li{
padding:0 0 7px 10px;
color:#c0c0c0;
font-size:14px;
font-weight:bold;
}
/========= SINGLE POST SPECIFIC =========/
.singletags {
margin-top:5px;
font-weight:bold;
color:#C0C0C0;
}
.entry p{
text-align:left;
font-size:12px;
line-height:20px;
}
.entry blockquote {
padding: 3px 15px;
background: #def3ff;
border: 1px solid #0253b8;
margin: 5px auto 15px auto;
color:#000;
width:85%;
}
.entry blockquote p {
font-size:12px;
padding: 5px 0px;
margin: 5px 0px;
line-height: 20px;
}
.entry img {
padding: 2px 2px 2px 2px;
background:#DDD;
border: solid 1px #C0C0C0;
}
.entry ul, .entry ol {
margin-bottom:15px;
font-size:12px;
line-height:20px;
}
.entry ul li ul, .entry ol li ol{
margin-bottom:0px;
padding-top:3px;
}
.entry ul li {
list-style:circle inside !important;
margin-left:15px;
padding:3px 0px;
}
.entry ul li ul li {
list-style:disc inside !important;
}
.entry ol li {
list-style:decimal inside !important;
font-size:12px;
padding:3px 0px;
}
.entry ol li ol li {
list-style:decimal-leading-zero inside !important;
}
/========= COMMENTS =========/
h2.commh2{
font-size: 1.4em;
padding: 0 0 5px;
font-weight:bold !important;
}margin: 10px 0 20px;
padding: 0;
list-style: none;
font-size: 12px;
line-height: 20px;
}margin-bottom:10px;
line-height: 20px;
}font-style: normal;
font-weight: bold;
}padding: 20px 10px 10px 10px;
}padding: 10px 10px 0 10px !important;
background:#DDD;
border:1px solid #C0C0C0;
}
/========= SIDEBAR =========/
/- Sidebar Tabs - Popular, Comentários, Destaques, Nuvem de Tags -/
.sideTabs {
border-bottom:1px solid #C0C0C0;
height:31px;
width:350px;
float:left;
display:block;
}font-size: 12px;
height: 30px;
letter-spacing: -1px;
}float: left;
font-size: 13px;
line-height: 30px;
}background: #eeeeee;
border: 1px solid #eeeeee;
border-bottom: 0;
color: #c0c0c0;
display: block;
margin: 0 2px 0 0;
padding: 0 10px;
font-weight:bold;
}background: #dddddd;
border: 1px solid #c0c0c0;
border-bottom:1px solid #ddd;
color: #373737;
text-decoration: none;
}
.navbox{
background: #dddddd;
border: 1px solid #c0c0c0;
border-top: 0;
margin: -2px 0 25px;
padding: 10px 10px 0;
position: relative;
}padding-bottom:12px;
}background: url(images/ico-star.gif) no-repeat left center;
padding: 6px 0 6px 25px;
border-bottom:1px dashed #C0C0C0;
}color: #000000;
}background: url(images/ico-mostcomm.gif) no-repeat left center !important;
}background: url(images/ico-feat.gif) no-repeat left center !important;
}.ads{
border: 1px solid #eeeeee;
height: 125px;
margin: 0 0 25px;
padding: 10px;
}float: left;
margin: 0 14px 0 0;
}margin: 0 !important;
}.flickr{
background: #fafafa;
border: 1px solid #c0c0c0;
margin: 0 0 25px;
padding: 10px 0px;
}float:left;
display:inline;
padding-left:10px;
padding-bottom:5px;
}color: #ff7800;
font-size: 14px;
height: 21px;
margin: 0 0 10px 0px;
padding-left:10px;
}float: left;
}float: right;
margin: 0 2px;
}color: #848382;
float: right;
font-style: normal;
}
.flickr-ar {
margin:10px 10px 0px 0px !important;
padding:0px !important;
text-align:right;
}
/=== DropDown Lists ===/
.catlist{
border-bottom: 3px solid #c0c0c0;
margin: 0 0 15px;
padding: 0 0 10px;
width: 160px;
}color: #ff7800;
font-size: 14px;
padding: 0 20px 0 0 !important;
background:url(images/ico-catlist.gif) center right no-repeat;
}
.list-alt {
padding-top:10px;
}margin: 0 0 7px;
}color: #000000;
}text-transform:uppercase;
}background: url(images/hl-dot.gif) repeat-x bottom;
margin: 0 0 15px;
padding: 10px 0 7px;
}margin: 0 0 7px;
}color: #000000;
}
/========= FOOTER =========/
#footer{
background: #000000;
clear: both;
color: #b3b3b3;
height: 35px;
line-height: 35px;
padding: 0 15px;
}
#footer a{
color: #b3b3b3;
}
#footer img {
vertical-align:middle;
}
/========= MISC =========/
.fix{
clear: both;
height: 1px;
margin: 0 0 -1px;
overflow: hidden;
}
.hl{
background: url(images/hl-dot.gif) repeat-x bottom;
}
.hl-full{
background: url(images/hl-dot-full.gif) repeat-x bottom;
float:left;
clear:both;
height:2px;
width:100%;
margin:20px 0 25px !important;
margin:10px 0 15px;
padding:0 !important;
}
.hl2{
border-bottom: 3px solid #c0c0c0;
}
.hl3{
border-top: 3px solid #c0c0c0;
padding: 10px 0 0;
}
.blog{
width:100% !important;
float:left;
}
.between{
height:2px;
margin-bottom:15px;
}
.fl{
float: left;
}
.fr{
float: right;
}
.ac{
text-align: center;
}
.ar{
text-align: right;
}
.th{
border: 1px solid #c0c0c0;
float: left;
margin: 0 10px 0 0;
padding: 3px;
}
.gravatar {
float:left;
border: 1px solid #000;
margin-right: 10px;
}
/=== Gravity forms ===/
.gfield { margin-bottom: 10px; }
.gform_wrapper .top_label .gfield_label { display:block;float:left; padding-right:20px; width: 80px; margin: 5px 0px 4px !important; }
.gform_wrapper input.button { padding: 5px 10px 6px !important; border: 0px !important; }
.gform_wrapper input { padding: 5px 3px !important; }
.gform_wrapper .top_label input.large, .gform_wrapper .top_label select.large, .gform_wrapper .top_label textarea.textarea { width: 300px !important; padding: 7px 3px !important; }
.gform_wrapper .entry img, .gform_wrapper img.thumbnail { padding: 0px !important; border: 0px !important; }
ul.top_label .clear-multi { clear: none !important; }
.gform_wrapper .gfield_checkbox, .gform_wrapper .gfield_radio { margin-left: 120px !important; }
img.ui-datepicker-trigger { border: 0px; padding: 0px; }
.entry .gform_wrapper .gfield_checkbox li, .gform_wrapper .gfield_radio li { list-style: none !important; }
Editando facebook-comments-for-wordpress/facebook-comments.php (ativo)
<?php
/*
Plugin Name: Facebook Comments for WordPress
Plugin URI: http://we8u.com/facebook-comments
Description: Allows your visitors to comment on posts using their Facebook profile. Supports custom styles, notifications, combined comment counts, etc.
Author: we8u
Version: 3.1.3
Author URI: http://we8u.com/
*/
define('FBCOMMENTS_ERRORS', false); # Set to true while developing, false for a release
define('FBCOMMENTS_VER', '3.1.3');
define('FBCOMMENTS_REQUIRED_PHP_VER', '5.0.0');
define('FBCOMMENTS_AUTHOR', 'we8u');
define('FBCOMMENTS_WEBPAGE', 'http://we8u.com/facebook-comments/');
define('FBCOMMENTS_PATH', plugins_url('facebook-comments-for-wordpress/'));
define('FBCOMMENTS_CSS_ADMIN', FBCOMMENTS_PATH . 'css/facebook-comments.css');
define('FBCOMMENTS_CSS_HIDEWPCOMMENTS', FBCOMMENTS_PATH . 'css/facebook-comments-hidewpcomments.css');
define('FBCOMMENTS_CSS_HIDEFBLINK', FBCOMMENTS_PATH . 'css/facebook-comments-hidefblink.css');
define('FBCOMMENTS_CSS_HIDELIKE', FBCOMMENTS_PATH . 'css/facebook-comments-hidelike.css');
define('FBCOMMENTS_CSS_DARKSITE', FBCOMMENTS_PATH . 'css/facebook-comments-darksite.css');
define('FBCOMMENTS_CSS_HIDELIKEANDDARKSITE', FBCOMMENTS_PATH . 'css/facebook-comments-custom.css');
define('FBCOMMENTS_CSS_WIDGETS', FBCOMMENTS_PATH . 'css/facebook-comments-widgets.css');
if (FBCOMMENTS_ERRORS) {
error_reporting(E_ALL); # Ensure all errors and warnings are verbose
}
require_once 'facebook-comments-core.php';
require_once 'facebook-comments-recentcomments.php';
require_once 'facebook-comments-combinecomments.php';
require_once 'facebook-comments-display.php';
require_once 'scripts/facebook.php'; # Facebook API wrapper
wp_enqueue_script('jquery');
/**********************************
Globals
**********************************/
global $fbComments_defaults;
$fbComments_defaults = array(
'appId' => '',
'appSecret' => '',
'accessToken' => null,
'xid' => fbComments_getRandXid(),
'includeFbJs' => true,
'includeFbJsOldWay' => false,
'includeFbmlLangAttr' => true,
'includeOpenGraphLangAttr' => true,
'includeOpenGraphMeta' => true,
'includeFbComments' => true,
'hideWpComments' => false,
'combineCommentCounts' => true,
'notify' => true,
'language' => 'en_US',
'displayTitle' => true,
'title' => 'facebook comments:',
'numPosts' => 10,
'width' => 500,
'displayLocation' => 'before',
'displayPagesOrPosts' => 'posts',
'publishToWall' => true,
'reverseOrder' => false,
'hideFbLikeButton' => false,
'containerCss' => 'margin: 20px 0;',
'titleCss' => 'margin-bottom: 15px; font-size: 140%; font-weight: bold; border-bottom: 2px solid #000; padding-bottom: 5px;',
'darkSite' => '',
'noBox' => false,
'dashNumComments' => 10,
'v1plusv2' => false,
// 'newUser' => false,
'notifyUserList' => '',
'showDBWidget' => false,
'enableCache' => false,
'commentVersion' => 'new',
'fbCommentCount' => true,
'v2ccstyle' => 'border:none; overflow:hidden; width:130px; padding-left:-15px; height:12px;',
'indexLikebtn' => array( 'display' => 'none',
'layout' => 'button_count',
'showFaces' => true,
'width' => 450,
'verb' => 'like',
'font' => 'arial',
'color' => 'light',
'style' => 'height: 25px; width: 150px; border: medium none; overflow: hidden;'
),
'like' => array( 'layout' => 'standard',
'showFaces' => true,
'width' => 450,
'verb' => 'like',
'font' => 'arial',
'color' => 'light',
'style' => 'height: 62px; width: 100%;'
)
);
/**********************************
Activation hooks/actions
**********************************/
fbComments_doUpdate();
}
register_activation_hook(__FILE__, 'fbComments_init_hack');
register_deactivation_hook(__FILE__, 'fbComments_deactivate_hack'); # hack may not be needed here
register_uninstall_hook(__FILE__, 'fbComments_uninit_hack'); # or here
function fbComments_init_hack() { fbComments_init(); }
function fbComments_deactivate_hack() { fbComments_deactivate(); }
function fbComments_uninit_hack() { fbComments_uninit(); }
global $fbc_options; # main options array in wp database options table
$fbc_options = get_option('fbComments');
add_action('admin_notices', create_function( '', "echo '<div class=\"error\"><p><strong>".sprintf(__('The Facebook comments box will not be included in your posts until you set a valid application ID and application secret. Please <a href="%s">set your application ID and secret now</a> using the options page.', 'facebook-comments'), admin_url('options-general.php?page=facebook-comments'))."</strong></p></div>';" ) );
# display the message only upon activation
update_option('fbComments_displayAppIdWarning', false);
}
if ($fbc_options['hideWpComments']) {
function fbComments_enqueueHideWpCommentsCss() {
wp_register_style('fbComments_hideWpComments', FBCOMMENTS_CSS_HIDEWPCOMMENTS, array(), FBCOMMENTS_VER);
wp_enqueue_style('fbComments_hideWpComments');
}
add_action('init', 'fbComments_enqueueHideWpCommentsCss');
}
function fbComments_includeLangAttrs($attributes='') {
$opts = get_option('fbComments');
if ($opts['includeFbmlLangAttr']) {
$attributes .= ' xmlns:fb="http://www.facebook.com/2008/fbml"';
}
if ($opts['includeOpenGraphLangAttr']) {
$attributes .= ' xmlns:og="http://opengraphprotocol.org/schema/"';
}
return $attributes;
}
add_filter('language_attributes', 'fbComments_includeLangAttrs');
}
if ($fbc_options['includeOpenGraphMeta']) {
function fbComments_addOpenGraphMeta() {
global $wp_query;
global $fbc_options;
$postId = $wp_query->post->ID;
$postTitle = single_post_title('', false);
$postUrl = get_permalink($postId);
$siteName = get_bloginfo('name');
$appId = $fbc_options['appId'];
if (strlen($fbc_options['notifyUserList']) > 0) { echo "<meta property='fb:admins' content='{$fbc_options['notifyUserList']}'>"; }
echo "<meta property='og:title' content='$postTitle' />",
"<meta property='og:site_name' content='$siteName' />",
"<meta property='og:url' content='$postUrl' />",
"<meta property='og:type' content='article' />",
"<meta property='fb:app_id' content='$appId'>\n";
}
add_action('wp_head', 'fbComments_addOpenGraphMeta');
}
/**********************************
Settings page
**********************************/
add_action('admin_init', 'fbComments_adminPage_init' );
add_action('admin_menu', 'fbComments_adminPage');
function fbComments_adminPage_init() {
register_setting('fbComments_options', 'fbComments', 'fbComments_sanatize');
}
function fbComments_adminPage() {
add_options_page(__('Facebook Comments for WordPress Options'), __('Facebook Comments'), 'manage_options', 'facebook-comments', 'fbComments_includeAdminPage');
}
function fbComments_includeAdminPage() {
include('facebook-comments-admin.php');
}
function fbComments_sanatize($input) {
$input['title'] = esc_attr($input['title']);
$input['containerCss'] = esc_attr($input['containerCss']);
$input['titleCss'] = esc_attr($input['titleCss']);
$input['dashNumComments'] = absint($input['dashNumComments']);
$input['numPosts'] = absint($input['numPosts']);
$input['width'] = absint($input['width']);
return $input;
}
add_filter('plugin_action_links', 'fbComments_settingsLink', 0, 2);
function fbComments_settingsLink($actionLinks, $file) {
if (($file == 'facebook-comments-for-wordpress/facebook-comments.php') && function_exists('admin_url')) {
$settingsLink = '<a href="' . admin_url('options-general.php?page=facebook-comments') . '">' . __('Settings') . '</a>';
# Add 'Settings' link to plugin's action links
array_unshift($actionLinks, $settingsLink);
}
return $actionLinks;
}
add_action('wp_dashboard_setup', 'fbcomments_add_dashboard_widgets');
# register FBCRC_Widget widget
add_filter('the_posts', 'conditionally_add_scripts_and_styles'); # the_posts gets triggered before wp_head
add_action('widgets_init', create_function('', 'return register_widget("FBCRC_Widget");'));
}
/**********************************
Program entry point
**********************************/
if ($fbc_options['includeFbComments']) {
add_filter('comments_array', 'facebook_comments');
}
if ('top' == $fbc_options['indexLikebtn']['display'] || 'bottom' == $fbc_options['indexLikebtn']['display']) {
add_filter('the_content', 'fbc_show_like_index');
}
if ($fbc_options['fbCommentCount'] && $fbc_options['commentVersion'] == 'v2') {
add_filter('comments_number', 'fbc_facebook_comment_count');
add_filter('get_comments_number', 'fbComments_combineCommentCounts');
}
?>Carregando comentários...