diff --git a/sidebars/widgets.php b/sidebars/widgets.php new file mode 100644 index 0000000..8e9811f --- /dev/null +++ b/sidebars/widgets.php @@ -0,0 +1,57 @@ + __( 'Widget per l\'inserimento della sidebar dei contenuti didattici', 'text_domain' ), ) // Args + ); + } + + /** Front-end display of widget */ + public function widget( $args, $instance ) { + extract( $args ); + $shortcode = do_shortcode('[sbdidattica]'); + echo $shortcode; + echo $after_widget; + } + + /** Back-end widget form */ + public function form( $instance ) { + if ( isset( $instance[ 'title' ] ) ) { + $title = $instance[ 'title' ]; + } + else { + $title = __( 'Titolo', 'text_domain' ); + } + ?> +
+ + +
+