GiV
Junior Member | Редактировать | Профиль | Сообщение | Цитировать | Сообщить модератору catbegemot ммм... а ты наверное хотел что бы они вообще были убраны, а не оставались, но были неактивны. тогда $row['post'] = preg_replace( "#<a href=[\"'](http://|https://|ftp://|news://)?(\S+?)['\"].+?".">(.+?)</a>#" , "Links Disabled To Guests. Please Register" , $row['post'] ); Добавлено: catbegemot тьфу блин... не понял вопроса ./sources/lib/post_parser.php найти: Код: $txt = preg_replace( "#(^|\s)((http|https|news|ftp)://\w+[^\s\[\]]+)#ie" , "\$this->regex_build_url(array('html' => '\\2', 'show' => '\\2', 'st' => '\\1'))", $txt ); | заменить на: Код: if ( $ibforums->member['id'] ) { $txt = preg_replace( "#(^|\s)((http|https|news|ftp)://\w+[^\s\[\]]+)#ie" , "\$this->regex_build_url(array('html' => '\\2', 'show' => '\\2', 'st' => '\\1'))", $txt ); } else { $txt = preg_replace( "#(^|\s)((http|https|news|ftp)://\w+[^\s\[\]]+)#i" , "", $txt ); } | ниже найти: Код: $txt = preg_replace( "#\[url\](\S+?)\[/url\]#ie" , "\$this->regex_build_url(array('html' => '\\1', 'show' => '\\1'))", $txt ); $txt = preg_replace( "#\[url\s*=\s*\"\;\s*(\S+?)\s*\"\;\s*\](.*?)\[\/url\]#ie" , "\$this->regex_build_url(array('html' => '\\1', 'show' => '\\2'))", $txt ); $txt = preg_replace( "#\[url\s*=\s*(\S+?)\s*\](.*?)\[\/url\]#ie" , "\$this->regex_build_url(array('html' => '\\1', 'show' => '\\2'))", $txt ); | заменить на: Код: if ( $ibforums->member['id'] ) { $txt = preg_replace( "#\[url\](\S+?)\[/url\]#ie" , "\$this->regex_build_url(array('html' => '\\1', 'show' => '\\1'))", $txt ); $txt = preg_replace( "#\[url\s*=\s*\"\;\s*(\S+?)\s*\"\;\s*\](.*?)\[\/url\]#ie" , "\$this->regex_build_url(array('html' => '\\1', 'show' => '\\2'))", $txt ); $txt = preg_replace( "#\[url\s*=\s*(\S+?)\s*\](.*?)\[\/url\]#ie" , "\$this->regex_build_url(array('html' => '\\1', 'show' => '\\2'))", $txt ); } else { $txt = preg_replace( "#\[url\](\S+?)\[/url\]#i" , "", $txt ); $txt = preg_replace( "#\[url\s*=\s*\"\;\s*(\S+?)\s*\"\;\s*\](.*?)\[\/url\]#i" , "", $txt ); $txt = preg_replace( "#\[url\s*=\s*(\S+?)\s*\](.*?)\[\/url\]#i" , "", $txt ); } | сорри, туплю | Всего записей: 74 | Зарегистр. 05-05-2004 | Отправлено: 22:59 09-03-2005 | Исправлено: GiV, 23:00 09-03-2005 |
|