Filter Reference / iworks upprev box title

Description

iworks_upprev_box_title is a filter applied to string witch is displayed as box title.

Usage

function my_title($title) {
    return 'some string';
}
add_filter('iworks_upprev_box_title', 'my_title');

Return some string to display as a title of box.

Return false to turn off box title.

Parameters

$title
(string) (required) upPrev box title.

Default: depend of settings

Examples

For posts in category “Hot News”, show as box title “Read next HOT news”.

add_filter(
    'iworks_upprev_check',
    'my_title_for_category_hot_news',
);
function my_title_for_category_hot_news($title) {
    if( is_post() && in_category('Hot News') ) {
        return __('Read next HOT news', 'i18n-domain');
    }
    return $title;
}

Change Log

Leave a Reply

Your email address will not be published. Required fields are marked *