name = 'Heading';
$this->id_base = 'heading';
$this->description = 'Heading typography, can be used as widget title or label.';
}
public function widget( $instance, $args = array() ){
if(!isset( $instance['tag'] )){
$instance['tag'] = 'h3';
}
if(!isset( $instance['class'] )){
$instance['class'] = '';
}
if(!isset( $instance['text'] )){
$instance['text'] = '';
}
echo '<'.$instance['tag'].' class="'.$instance['class'].'">';
echo htmlentities($instance['text']);
echo ''.$instance['tag'].'>';
}
public function form( $instance = array() ){
if(!isset( $instance['tag'] )){
$instance['tag'] = 'h3';
}
if(!isset( $instance['class'] )){
$instance['class'] = '';
}
if(!isset( $instance['text'] )){
$instance['text'] = '';
}
?>
name = 'Banner Ad';
$this->id_base = 'banner_ad';
$this->description = 'Show banner advertisement';
}
public function widget( $instance, $args = array() ){
echo '
';
echo $instance['text'];
echo '
';
}
public function form( $instance = array() ){
if(!isset( $instance['text'] )){
$instance['text'] = '';
}
?>
This widget is similar to HTML widget, the difference is that it comes with a banner div to fit the theme style. You can also style it on theme style.css