function EducateEllipses in Typogrify 7
Same name and namespace in other branches
- 5 smartypants.php \EducateEllipses()
- 6 smartypants.php \EducateEllipses()
EducateEllipses. Example input: Huh...? Example output: Huh…?
Parameters
string $_: Input text.
Return value
string The string, with each instance of "..." translated to an ellipsis HTML entity. Also converts the case where there are spaces between the dots.
2 calls to EducateEllipses()
- SmartEllipses in ./
smartypants.php - SmartEllipses.
- SmartyPants in ./
smartypants.php - SmartyPants.
File
- ./
smartypants.php, line 1030 - SmartyPants - Smart punctuation for web sites
Code
function EducateEllipses($_) {
$_ = str_replace(array(
"...",
". . .",
), '…', $_);
return $_;
}