WPDIR
Everything and everyone WordPress

how to hide titles from only certain WordPress widgets?

  • This topic is empty.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #313 Reply
    Kathleen
    Guest

    I saw a goofy solution hiding all titles using a filter but I want only for certain widgets.

    #314 Reply
    Angela
    Guest

    this plugin does it but for ALL widgets seems

    Remove Widget Titles

    #315 Reply
    Steven
    Guest

    // REMOVE WIDGET TITLE IF IT BEGINS WITH EXCLAMATION POINT
    add_filter( ‘widget_title’, ‘remove_widget_title’ );

    function remove_widget_title( $widget_title ) {

    if ( substr ( $widget_title, 0, 1 ) == ‘!’ )

    return;

    else

    return ( $widget_title );

    kinda janky solution where you put a exclamation point in front of the title to hide it

    Source: https://www.acmethemes.com/blog/how-to-hide-widget-titles-in-wordpress/

Viewing 3 posts - 1 through 3 (of 3 total)
Reply To: how to hide titles from only certain WordPress widgets?