mirror of
https://git.friendi.ca/friendica/friendica-addons.git
synced 2024-11-22 07:43:41 +00:00
nsfw update to shared tags
This commit is contained in:
parent
5d21b7256b
commit
94e8c206ec
2 changed files with 6 additions and 2 deletions
BIN
nsfw.tgz
BIN
nsfw.tgz
Binary file not shown.
|
@ -87,7 +87,11 @@ function nsfw_prepare_body(&$a,&$b) {
|
|||
continue;
|
||||
}
|
||||
|
||||
if(stristr($b,$word)) {
|
||||
if(stristr($b['html'],$word)) {
|
||||
$found = true;
|
||||
break;
|
||||
}
|
||||
if(stristr($b['item']['tag'], ']' . $word . '[' )) {
|
||||
$found = true;
|
||||
break;
|
||||
}
|
||||
|
@ -95,6 +99,6 @@ function nsfw_prepare_body(&$a,&$b) {
|
|||
}
|
||||
if($found) {
|
||||
$rnd = random_string(8);
|
||||
$b = '<div id="nsfw-wrap-' . $rnd . '" class="fakelink" onclick=openClose(\'nsfw-' . $rnd . '\'); >' . t('NSFW - Click to open/close') . '</div><div id="nsfw-' . $rnd . '" style="display: none; " >' . $b . '</div>';
|
||||
$b['html'] = '<div id="nsfw-wrap-' . $rnd . '" class="fakelink" onclick=openClose(\'nsfw-' . $rnd . '\'); >' . t('NSFW - Click to open/close') . '</div><div id="nsfw-' . $rnd . '" style="display: none; " >' . $b['html'] . '</div>';
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue