Successful adding twitter sidebar widget on my blog

Adding twitter sidebar widget on my blog to day. I put a little code in to my sidebar.php, couse this template have no support widget yet in the function.

my twitter page

in the sidebar.php i put a litte code:

<div>
<div>
<?php if (function_exists(‘dynamic_sidebar’) && dynamic_sidebar(1) ) : else : ?>
<?php endif; ?>
<?php if (function_exists(‘dynamic_sidebar’) && dynamic_sidebar(2) ) : else : ?>
<?php endif; ?>
<?php if (function_exists(‘dynamic_sidebar’) && dynamic_sidebar(3) ) : else : ?>
<?php endif; ?>
</div>
</div>

and in the function.php i put this code:

if ( function_exists(‘register_sidebar’) )
register_sidebar(array(
‘before_widget’ => ‘<li id=”%1$s”>’,
‘after_widget’ => ‘</li>’,
‘before_title’ => ‘<h2>’,
‘after_title’ => ‘</h2>’,
));

ok, thats my tips to day 🙂

Tinggalkan Balasan

Alamat email Anda tidak akan dipublikasikan. Ruas yang wajib ditandai *


*