ndexa
  • Fatal Error
    Fatal Error: could not open XML input (http://news.yandex.ru/index.rss)...
    >>

: .

: 2.2

:

: engine/forum/action/addpost.php

:

<!-- code1 -->
<!-- ecode1 --> if ($forum_config['subscription'] AND !$stop_subscription)
{
$all_subscr = $db->query("SELECT * FROM ". PREFIX ."_forum_subscription WHERE topic_id = '$topic_id' and user_id != '$member_id[user_id]'");

if ($db->num_rows($all_subscr))
{
include_once ENGINE_DIR.'/classes/mail.class.php';

$mail = new dle_mail ($config);

$topic_link = $forum_url."showtopic={$topic_id}";

$topic_link_del = $config['http_home_url']."?do=forum&act=subscription&code=del&selected_id={$topic_id}";

$mail_tpl = $db->super_query("SELECT template FROM " . PREFIX . "_forum_email where name='subscription_text' LIMIT 0,1");

$mail_tpl['template'] = stripslashes($mail_tpl['template']);

while ($mail_row = $db->get_row($all_subscr))
{
$mail_result = str_replace("{%username_to%}", $mail_row['name'], $mail_tpl['template']);

$mail_result = str_replace("{%username_from%}", $member_id['name'], $mail_result);

$mail_result = str_replace("{%topic_name%}", " $topic_id", $mail_result);

$mail_result = str_replace("{%topic_link%}", $topic_link, $mail_result);

$mail_result = str_replace("{%topic_link_del%}", $topic_link_del, $mail_result);

$mail_title = " ";

$mail->send ($mail_row['email'], $mail_title, $mail_result);
}

}
} <!-- code2 -->
<!-- ecode2 -->

:

<!-- code1 --> <!-- ecode1 --> if ($forum_config['subscription'] AND !$stop_subscription)
{
$all_subscr = $db->query("SELECT name, email FROM ". PREFIX ."_forum_subscription AS t1 INNER JOIN ". PREFIX ."_users AS t2 ON t1.user_id = t2.user_id WHERE t1.topic_id = $topic_id and t1.user_id != {$member_id['user_id']}");

if ($db->num_rows($all_subscr))
{
include_once ENGINE_DIR.'/classes/mail.class.php';

$mail = new dle_mail ($config);

$topic_link = $forum_url."showtopic={$topic_id}";

$topic_link_del = $config['http_home_url']."?do=forum&act=subscription&code=del&selected_id={$topic_id}";

$mail_tpl = $db->super_query("SELECT template FROM " . PREFIX . "_forum_email where name='subscription_text' LIMIT 0,1");

$mail_tpl['template'] = stripslashes($mail_tpl['template']);

while ($mail_row = $db->get_row($all_subscr))
{
$mail_result = str_replace("{%username_to%}", $mail_row['name'], $mail_tpl['template']);

$mail_result = str_replace("{%username_from%}", $member_id['name'], $mail_result);

$mail_result = str_replace("{%topic_name%}", $topic_title, $mail_result);

$mail_result = str_replace("{%topic_link%}", $topic_link, $mail_result);

$mail_result = str_replace("{%topic_link_del%}", $topic_link_del, $mail_result);

$mail_title = " ";

$mail->send ($mail_row['email'], $mail_title, $mail_result);
}

}
}


Alexander, -. , 22363

  (0)

?