Lektor
Проблемка имеет место быть. Проверьте сами, впишите в заголовок спойлера какой-нибудь алерт-javascript.
if( preg_match('#\[spoiler=\\\"#si', $possible_start, $match) && !preg_match('#\[spoiler=\\\"(.*?)\\\"\]#si', $possible_start) )
{
if ($close_pos = strpos($text, '"]', $curr_pos + 14))
{
if (strpos(substr($text, $curr_pos + 14, $close_pos - ($curr_pos + 14)), '[spoiler') === false)
{
$possible_start = substr($text, $curr_pos, $close_pos - $curr_pos + 7);
}
}
}function fixPostImage ($img)
{
var banned_image_hosts = /imagebanana|hidebehind/i; // imageshack
var src = $img[0].src;
if (src.match(banned_image_hosts)) {
$img.wrap('<a href="'+ this.src +'" target="_blank"></a>').attr({ src: "./images/tr_oops.gif", title: "Host for this image is banned!" });
}
return $img;
}
function fixPostImage ($img)
{
var allowed_image_hosts = /внутрисетевой_домен1|внутрисетевой_домен2|внутрисетевой_домен3|192\.168\.\d+\.\d+/i;
var src = $img[0].src;
if (!(src.match(allowed_image_hosts))) {
$img.wrap('<a href="'+ this.src +'" target="_blank"></a>').attr({ src: "./images/tr_oops.gif", title: "Host for this image is not allowed.
return $img;
}[spoiler]{TEXT}[/spoiler]<div id="spoiler"><div><input type="button" value="Показать спойлер" style="width:150px;font-size:12px;margin:10px;padding:0px;" onclick="if (this.parentNode.parentNode.getElementsByTagName('div')['show'].style.display != '') { this.parentNode.parentNode.getElementsByTagName('div')['show'].style.display = ''; this.parentNode.parentNode.getElementsByTagName('div')['hide'].style.display = 'none'; this.innerText = ''; this.value = 'Спрятать спойлер'; } else { this.parentNode.parentNode.getElementsByTagName('div')['show'].style.display = 'none'; this.parentNode.parentNode.getElementsByTagName('div')['hide'].style.display = ''; this.innerText = ''; this.value = 'Еще раз показать?'; }" />
<div id="show" style="display: none; background-color:transparent; margin: 0px;border-style:solid;border-width:1px; padding: 4px; width:98%">{TEXT}</div>
<div id="hide"></div></div></div>[spoiler] TEXT [/spoiler]
Вернуться в Запросы модов для phpBB 2.0.x
Сейчас этот форум просматривают: нет зарегистрированных пользователей и гости: 0