Filter: wpt_custom_truncate

apply_filters( 'wpt_custom_truncate', $post_tweet, $tweet, $post_ID, $retweet, $reference ) → {string}

Filter a Tweet template that does not contain any WP to Twitter template tags.

Parameters:
Name Type Description
$post_tweet string

Text to Tweet truncated to maximum allowed length.

$tweet string

Original passed text.

$post_ID int

Post ID.

$retweet bool

Boolean flag that indicates whether this is being reposted.

$reference int

Pass reference (1).

Source:
Returns:
Type
string

apply_filters( 'wpt_custom_truncate', $post_tweet, $tweet, $post_ID, $retweet, $reference ) → {string}

Filter a Tweet template after all content checks are completed.

Parameters:
Name Type Description
$post_tweet string

Text to Tweet truncated to maximum allowed length.

$tweet string

Original passed text.

$post_ID int

Post ID.

$retweet bool

Boolean flag that indicates whether this is being reposted.

$reference int

Pass reference (3).

Source:
Returns:
Type
string

apply_filters( 'wpt_custom_truncate', $post_tweet, $tweet, $post_ID, $retweet, $reference ) → {string}

Filter a Tweet template after tags have been parsed but prior to truncating for length.

Parameters:
Name Type Description
$post_tweet string

Text to Tweet truncated to maximum allowed length.

$tweet string

Original passed text.

$post_ID int

Post ID.

$retweet bool

Boolean flag that indicates whether this is being reposted.

$reference int

Pass reference (2).

Source:
Returns:
Type
string