We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents b234d59 + fb3599a commit 84e3a56Copy full SHA for 84e3a56
1 file changed
app/helpers/Markdown/TitleIdPreprocessor.php
@@ -45,6 +45,7 @@ public static function headlineTextToHtmlId($headlineText)
45
{
46
$headlineText = strip_tags($headlineText);
47
$headlineText = trim($headlineText);
48
+ $headlineText = preg_replace("/&#?[a-z0-9]{2,8}; /i","",$headlineText); // remove "& " from string
49
$headlineText = preg_replace('/\s/', '-', $headlineText);
50
$headlineText = preg_replace('/[^a-zA-Z0-9\-\_]/', '', $headlineText);
51
$headlineText = preg_replace('/(\-)+/', '-', $headlineText);
0 commit comments