Merge pull request #8302 from annando/allowed-chars
Added characters to the disallowed hashtag characters
This commit is contained in:
commit
d09b3f5bde
|
@ -103,8 +103,7 @@ function add_page_info_data(array $data, $no_photos = false)
|
||||||
$hashtags = "\n";
|
$hashtags = "\n";
|
||||||
foreach ($data["keywords"] as $keyword) {
|
foreach ($data["keywords"] as $keyword) {
|
||||||
/// @TODO make a positive list of allowed characters
|
/// @TODO make a positive list of allowed characters
|
||||||
$hashtag = str_replace([" ", "+", "/", ".", "#", "'", "’", "`", "(", ")", "„", "“"],
|
$hashtag = str_replace([' ', '+', '/', '.', '#', '@', "'", '"', '’', '`', '(', ')', '„', '“'], '', $keyword);
|
||||||
["", "", "", "", "", "", "", "", "", "", "", ""], $keyword);
|
|
||||||
$hashtags .= "#[url=" . DI::baseUrl() . "/search?tag=" . $hashtag . "]" . $hashtag . "[/url] ";
|
$hashtags .= "#[url=" . DI::baseUrl() . "/search?tag=" . $hashtag . "]" . $hashtag . "[/url] ";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue