1.Кнопка ДС++ не работала. Не прописана была команда на добавление кода
2.Магнет ссылки в именах файлов которых знаки восклицания не срабатывают.
Проверено на phpbb 2.0.23
Переделал, вроде бы все нормально. Ставил и в ручную и при помощи EasyMOD 0.4.0
Код: Выделить всё
##############################################################
## MOD Title: DC++ Magnet link in postmsg and privmsg
## MOD Author: Andrey Wolk < andy_wolk@mail.ru > (N/A) http://www.raswinbilling.ru
## MOD Description: This MOD allows inserting DC++ magnet links.
## MOD Version: 1.0.1
##
## Installation Level: Easy
## Installation Time: 5 Minutes
## Files To Edit: bbcode.php, bbcode.tpl, posting_body.tpl, posting.php, privmsg.php, lang_main.php
## Included Files: (N/A)
## License: http://opensource.org/licenses/gpl-license.php GNU General Public License v2
##############################################################
## For Security Purposes, Please Check: http://www.phpbb.com/mods/ for the
## latest version of this MOD. Downloading this MOD from other sites could cause malicious code
## to enter into your phpBB Forum. As such, phpBB will not offer support for MOD's not offered
## in our MOD-Database, located at: http://www.phpbb.com/mods/
##############################################################
## Author Notes:
##
##############################################################
## MOD History:
##
## 2006-11-24 - Version 1.0.0
## - Initial release tested with phpBB 2.0.21
## 2008-08-26 - Version 1.0.1
## - Initial release tested with phpBB 2.0.23
##
##############################################################
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
##############################################################
#
#-----[ OPEN ]------------------------------------------
#
includes/bbcode.php
#
#-----[ FIND ]------------------------------------------
#
, $bbcode_tpl['url4']);
#
#-----[ AFTER, ADD ]------------------------------------------
#
// [begin] DC++ Magnet link in postmsg and privmsg Mod
$bbcode_tpl['magnet1'] = str_replace('{MAGNET}', '\\1', $bbcode_tpl['magnet']);
$bbcode_tpl['magnet1'] = str_replace('{DESCRIPTION}', '\\1', $bbcode_tpl['magnet1']);
$bbcode_tpl['magnet2'] = str_replace('{MAGNET}', '\\1', $bbcode_tpl['magnet']);
$bbcode_tpl['magnet2'] = str_replace('{DESCRIPTION}', '\\2', $bbcode_tpl['magnet2']);
// [end] DC++ Magnet link in postmsg and privmsg Mod
#
#-----[ FIND ]------------------------------------------
#
= $bbcode_tpl['url4'];
#
#-----[ AFTER, ADD ]------------------------------------------
#
// [magnet]magnet:xxxx[/magnet] code..
$patterns[6] = "#\[magnet\]((magnet:)([\(\)\w\#$!%&~/.\-;:=,?@\]+]+|\[(?!url=))*?)\[/magnet\]#si";
$replacements[6] = $bbcode_tpl['magnet1'];
// [magnet=magnet:xxxx[/magnet] code..
$patterns[7] = "#\[magnet=(magnet:[\(\)\w\#$!%&~/.\-;:=,?@\[\]+]*?)\]([^?\n\r\t].*?)\[/magnet\]#si";
$replacements[7] = $bbcode_tpl['magnet2'];
#
#-----[ OPEN ]------------------------------------------
#
templates/subSilver/bbcode.tpl
#
#-----[ FIND ]------------------------------------------
#
<!-- BEGIN url --><a href="{URL}" target="_blank" class="postlink">{DESCRIPTION}</a><!-- END url -->
#
#-----[ AFTER, ADD ]------------------------------------------
#
<!-- BEGIN magnet --><a href="{MAGNET}" target="_blank" class="postlink">{DESCRIPTION}</a><!-- END magnet -->
#
#-----[ OPEN ]------------------------------------------
#
templates/subSilver/posting_body.tpl
#
#-----[ FIND ]------------------------------------------
#
f_help = "{L_BBCODE_F_HELP}";
#
#-----[ AFTER, ADD ]------------------------------------------
#
m_help = "{L_BBCODE_M_HELP}";
#
#-----[ FIND ]------------------------------------------
#
bbtags = new Array('[b]','[/b]','[i]','[/i]','[u]','[/u]','[quote]','[/quote]','[code]','
','
','
','[img]','[/img]','
','');
#
#-----[ IN-LINE FIND ]------------------------------------------
#
[img]','[/img]','
',''
#
#-----[ IN-LINE AFTER, ADD ]------------------------------------------
#
,'','','','','[magnet]','[/magnet]'
#
#-----[ FIND ]------------------------------------------
#
<td><span class="genmed">
<input type="button" class="button" accesskey="w" name="addbbcode16" value="URL" style="text-decoration: underline; width: 40px" onClick="bbstyle(16)" onMouseOver="helpline('w')" />
</span></td>
#
#-----[ AFTER, ADD ]------------------------------------------
#
<td><span class="genmed">
<input type="button" class="button" accesskey="m" name="addbbcode22" value="DC++" style="text-decoration: underline; width: 40px" onClick="bbstyle(22)" onMouseOver="helpline('m')" />
</span></td>
#
#-----[ OPEN ]------------------------------------------
#
posting.php
#
#-----[ FIND ]------------------------------------------
#
'L_BBCODE_S_HELP' => $lang['bbcode_s_help'],
'L_BBCODE_F_HELP' => $lang['bbcode_f_help'],
#
#-----[ AFTER, ADD ]------------------------------------
#
// [begin] DC++ Magnet link in postmsg and privmsg Mod
'L_BBCODE_M_HELP' => $lang['bbcode_m_help'],
// [end] DC++ Magnet link in postmsg and privmsg Mod
#
#-----[ OPEN ]------------------------------------------
#
privmsg.php
#
#-----[ FIND ]------------------------------------------
#
'L_BBCODE_S_HELP' => $lang['bbcode_s_help'],
'L_BBCODE_F_HELP' => $lang['bbcode_f_help'],
#
#-----[ AFTER, ADD ]------------------------------------------
#
// [begin] DC++ Magnet link in postmsg and privmsg Mod
'L_BBCODE_M_HELP' => $lang['bbcode_m_help'],
// [end] DC++ Magnet link in postmsg and privmsg Mod
#
#-----[ OPEN ]------------------------------------------
#
language/lang_russian/lang_main.php
#
#-----[ FIND ]------------------------------------------
#
$lang['bbcode_f_help'] = '
#
#-----[ AFTER, ADD ]------------------------------------------
#
// [begin] DC++ Magnet link in postmsg and privmsg Mod
$lang['bbcode_m_help'] = 'Вставить Magnet ссылку: [magnet]magnet:?[/magnet] или [magnet=magnet:?]текст ссылки[/magnet]';
// [end] DC++ Magnet link in postmsg and privmsg Mod
#
#-----[ OPEN ]------------------------------------------
#
language/lang_english/lang_main.php
#
#-----[ FIND ]------------------------------------------
#
$lang['bbcode_f_help'] = '
#
#-----[ AFTER, ADD ]------------------------------------
#
// [begin] DC++ Magnet link in postmsg and privmsg Mod
$lang['bbcode_m_help'] = 'Insert Magnet link: [magnet]magnet:?[/magnet] or [magnet=magnet:?]link text[/magnet]';
// [end] DC++ Magnet link in postmsg and privmsg Mod
#
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------
#
# EoM
[/code]