How to rename wordpress Widget

I want to rename “Widget” to something else

Like “Block” or something else.

Read More

please help me.

EDIT

Per the user’s comment below, she wants to change class="widget" to class="block" (or any arbitrary class name) in the rendered, sidebar Widget.

Related posts

Leave a Reply

1 comment

  1. The classes assigned to rendered Widgets are specified by the argument array passed to the register_sidebar() call used to register the sidebar. e.g.:

    <?php 
        $args = array(
            'name'          => sprintf(__('Sidebar %d'), $i ),
            'id'            => 'sidebar-$i',
            'description'   => '',
            'before_widget' => '<li id="%1$s" class="widget %2$s">',
            'after_widget'  => '</li>',
            'before_title'  => '<h2 class="widgettitle">',
            'after_title'   => '</h2>' ); 
    ?>
    

    See the before_widget parameter:

    'before_widget' => '<li id="%1$s" class="widget %2$s">'
    

    …change it accordingly, e.g. to:

    'before_widget' => '<li id="%1$s" class="block %2$s">'