本文整理汇总了PHP中vbmail_end函数的典型用法代码示例。如果您正苦于以下问题:PHP vbmail_end函数的具体用法?PHP vbmail_end怎么用?PHP vbmail_end使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了vbmail_end函数的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: send_issue_reply_notification
/**
* Sends the reply notification to users subscribed to this issue.
*
* @param array Info about this issue
* @param array Info about this note (including text)
*/
function send_issue_reply_notification($issue, $issuenote)
{
global $vbulletin, $db, $vbphrase;
if ($issuenote['type'] != 'user' and $issuenote['type'] != 'petition') {
// only send if the note is a "normal" note type
return;
}
$project = fetch_project_info($issue['projectid']);
$previousnote = $db->query_first("\r\n\t\tSELECT MAX(dateline) AS dateline\r\n\t\tFROM " . TABLE_PREFIX . "pt_issuenote AS issuenote\r\n\t\tWHERE issuenote.issueid = {$issue['issueid']}\r\n\t\t\tAND issuenote.dateline < {$issuenote['dateline']}\r\n\t\t\tAND issuenote.visible = 'visible'\r\n\t\t\tAND issuenote.type IN ('user', 'petition')\r\n\t");
$notifications = $db->query_read_slave("\r\n\t\tSELECT user.*\r\n\t\tFROM " . TABLE_PREFIX . "pt_issuesubscribe AS issuesubscribe\r\n\t\tINNER JOIN " . TABLE_PREFIX . "user AS user ON (issuesubscribe.userid = user.userid)\r\n\t\tLEFT JOIN " . TABLE_PREFIX . "usergroup AS usergroup ON (usergroup.usergroupid = user.usergroupid)\r\n\t\tLEFT JOIN " . TABLE_PREFIX . "usertextfield AS usertextfield ON (usertextfield.userid = user.userid)\r\n\t\tWHERE issuesubscribe.issueid = {$issue['issueid']}\r\n\t\t\tAND issuesubscribe.subscribetype = 'instant'\r\n\t\t\tAND (usergroup.genericoptions & " . $vbulletin->bf_ugp_genericoptions['isnotbannedgroup'] . ")\r\n\t\t\t" . ($issuenote['userid'] ? "AND CONCAT(' ', IF(usertextfield.ignorelist IS NULL, '', usertextfield.ignorelist), ' ') NOT LIKE ' " . intval($issuenote['userid']) . " '" : '') . "\r\n\t\t\tAND user.userid <> {$issuenote['userid']}\r\n\t\t\tAND user.lastactivity >= " . intval($previousnote['dateline']) . "\r\n\t");
if ($db->num_rows($notifications) == 0) {
return;
}
require_once DIR . '/includes/functions_misc.php';
require_once DIR . '/includes/class_bbcode_alt.php';
$plaintext_parser =& new vB_BbCodeParser_PlainText($vbulletin, fetch_tag_list());
$pagetext_cache = array();
// used to cache the results per languageid for speed
$evalemail = array();
$email_texts = $vbulletin->db->query_read_slave("\r\n\t\tSELECT text, languageid, fieldname\r\n\t\tFROM " . TABLE_PREFIX . "phrase\r\n\t\tWHERE fieldname IN ('emailsubject', 'emailbody') AND varname = 'notify_pt'\r\n\t");
while ($email_text = $vbulletin->db->fetch_array($email_texts)) {
$emails["{$email_text['languageid']}"]["{$email_text['fieldname']}"] = $email_text['text'];
}
foreach ($emails as $languageid => $email_text) {
// lets cycle through our array of notify phrases
$text_message = str_replace("\\'", "'", addslashes(iif(empty($email_text['emailbody']), $emails['-1']['emailbody'], $email_text['emailbody'])));
$text_message = replace_template_variables($text_message);
$text_subject = str_replace("\\'", "'", addslashes(iif(empty($email_text['emailsubject']), $emails['-1']['emailsubject'], $email_text['emailsubject'])));
$text_subject = replace_template_variables($text_subject);
$evalemail["{$languageid}"] = '
$message = "' . $text_message . '";
$subject = "' . $text_subject . '";
';
}
vbmail_start();
while ($notification = $vbulletin->db->fetch_array($notifications)) {
// check that this user has the correct permissions to view
if (verify_issue_perms($issue, $notification) === false or verify_issue_note_perms($issue, $issuenote, $notification) === false) {
continue;
}
$notification['username'] = unhtmlspecialchars($notification['username']);
$notification['languageid'] = iif($notification['languageid'] == 0, $vbulletin->options['languageid'], $notification['languageid']);
// parse the page text into plain text, taking selected language into account
if (!isset($pagetext_cache["{$notification['languageid']}"])) {
$plaintext_parser->set_parsing_language($notification['languageid']);
$pagetext_cache["{$notification['languageid']}"] = $plaintext_parser->parse($issuenote['pagetext'], 'pt');
}
$pagetext = $pagetext_cache["{$notification['languageid']}"];
eval(empty($evalemail["{$notification['languageid']}"]) ? $evalemail["-1"] : $evalemail["{$notification['languageid']}"]);
vbmail($notification['email'], $subject, $message);
}
unset($plaintext_parser, $pagetext_cache);
vbmail_end();
}
开发者ID:holandacz,项目名称:nb4,代码行数:60,代码来源:functions_pt_posting.php
示例2: exec_send_notification
//.........这里部分代码省略.........
* @param integer The Post ID of the new post
*
*/
function exec_send_notification($threadid, $userid, $postid)
{
// $threadid = threadid to send from;
// $userid = userid of who made the post
// $postid = only sent if post is moderated -- used to get username correctly
global $vbulletin, $message, $postusername;
if (!$vbulletin->options['enableemail']) {
return;
}
// include for fetch_phrase
require_once DIR . '/includes/functions_misc.php';
$threadinfo = fetch_threadinfo($threadid);
$foruminfo = fetch_foruminfo($threadinfo['forumid']);
// get last reply time
if ($postid) {
$dateline = $vbulletin->db->query_first("\n\t\t\tSELECT dateline, pagetext\n\t\t\tFROM " . TABLE_PREFIX . "post\n\t\t\tWHERE postid = {$postid}\n\t\t");
$pagetext_orig = $dateline['pagetext'];
$lastposttime = $vbulletin->db->query_first("\n\t\t\tSELECT MAX(dateline) AS dateline\n\t\t\tFROM " . TABLE_PREFIX . "post AS post\n\t\t\tWHERE threadid = {$threadid}\n\t\t\t\tAND dateline < {$dateline['dateline']}\n\t\t\t\tAND visible = 1\n\t\t");
} else {
$lastposttime = $vbulletin->db->query_first("\n\t\t\tSELECT MAX(postid) AS postid, MAX(dateline) AS dateline\n\t\t\tFROM " . TABLE_PREFIX . "post AS post\n\t\t\tWHERE threadid = {$threadid}\n\t\t\t\tAND visible = 1\n\t\t");
$pagetext = $vbulletin->db->query_first("\n\t\t\tSELECT pagetext\n\t\t\tFROM " . TABLE_PREFIX . "post\n\t\t\tWHERE postid = {$lastposttime['postid']}\n\t\t");
$pagetext_orig = $pagetext['pagetext'];
unset($pagetext);
}
$threadinfo['title'] = unhtmlspecialchars($threadinfo['title']);
$foruminfo['title_clean'] = unhtmlspecialchars($foruminfo['title_clean']);
$temp = $vbulletin->userinfo['username'];
if ($postid) {
$postinfo = fetch_postinfo($postid);
$vbulletin->userinfo['username'] = unhtmlspecialchars($postinfo['username']);
} else {
$vbulletin->userinfo['username'] = unhtmlspecialchars(!$vbulletin->userinfo['userid'] ? $postusername : $vbulletin->userinfo['username']);
}
require_once DIR . '/includes/class_bbcode_alt.php';
$plaintext_parser =& new vB_BbCodeParser_PlainText($vbulletin, fetch_tag_list());
$pagetext_cache = array();
// used to cache the results per languageid for speed
$mod_emails = fetch_moderator_newpost_emails('newpostemail', $foruminfo['parentlist'], $language_info);
($hook = vBulletinHook::fetch_hook('newpost_notification_start')) ? eval($hook) : false;
$useremails = $vbulletin->db->query_read_slave("\n\t\tSELECT user.*, subscribethread.emailupdate, subscribethread.subscribethreadid\n\t\tFROM " . TABLE_PREFIX . "subscribethread AS subscribethread\n\t\tINNER JOIN " . TABLE_PREFIX . "user AS user ON (subscribethread.userid = user.userid)\n\t\tLEFT JOIN " . TABLE_PREFIX . "usergroup AS usergroup ON (usergroup.usergroupid = user.usergroupid)\n\t\tLEFT JOIN " . TABLE_PREFIX . "usertextfield AS usertextfield ON (usertextfield.userid = user.userid)\n\t\tWHERE subscribethread.threadid = {$threadid} AND\n\t\t\tsubscribethread.emailupdate IN (1, 4) AND\n\t\t\tsubscribethread.canview = 1 AND\n\t\t\t" . ($userid ? "CONCAT(' ', IF(usertextfield.ignorelist IS NULL, '', usertextfield.ignorelist), ' ') NOT LIKE '% " . intval($userid) . " %' AND" : '') . "\n\t\t\tuser.usergroupid <> 3 AND\n\t\t\tuser.userid <> " . intval($userid) . " AND\n\t\t\tuser.lastactivity >= " . intval($lastposttime['dateline']) . " AND\n\t\t\t(usergroup.genericoptions & " . $vbulletin->bf_ugp_genericoptions['isnotbannedgroup'] . ")\n\t");
vbmail_start();
$evalemail = array();
while ($touser = $vbulletin->db->fetch_array($useremails)) {
if (!($vbulletin->usergroupcache["{$touser['usergroupid']}"]['genericoptions'] & $vbulletin->bf_ugp_genericoptions['isnotbannedgroup'])) {
continue;
} else {
if (in_array($touser['email'], $mod_emails)) {
// this user already received an email about this post via
// a new post email for mods -- don't send another
continue;
}
}
$touser['username'] = unhtmlspecialchars($touser['username']);
$touser['languageid'] = iif($touser['languageid'] == 0, $vbulletin->options['languageid'], $touser['languageid']);
$touser['auth'] = md5($touser['userid'] . $touser['subscribethreadid'] . $touser['salt'] . COOKIE_SALT);
if (empty($evalemail)) {
$email_texts = $vbulletin->db->query_read_slave("\n\t\t\t\tSELECT text, languageid, fieldname\n\t\t\t\tFROM " . TABLE_PREFIX . "phrase\n\t\t\t\tWHERE fieldname IN ('emailsubject', 'emailbody') AND varname = 'notify'\n\t\t\t");
while ($email_text = $vbulletin->db->fetch_array($email_texts)) {
$emails["{$email_text['languageid']}"]["{$email_text['fieldname']}"] = $email_text['text'];
}
require_once DIR . '/includes/functions_misc.php';
foreach ($emails as $languageid => $email_text) {
// lets cycle through our array of notify phrases
$text_message = str_replace("\\'", "'", addslashes(iif(empty($email_text['emailbody']), $emails['-1']['emailbody'], $email_text['emailbody'])));
$text_message = replace_template_variables($text_message);
$text_subject = str_replace("\\'", "'", addslashes(iif(empty($email_text['emailsubject']), $emails['-1']['emailsubject'], $email_text['emailsubject'])));
$text_subject = replace_template_variables($text_subject);
$evalemail["{$languageid}"] = '
$message = "' . $text_message . '";
$subject = "' . $text_subject . '";
';
}
}
// parse the page text into plain text, taking selected language into account
if (!isset($pagetext_cache["{$touser['languageid']}"])) {
$plaintext_parser->set_parsing_language($touser['languageid']);
$pagetext_cache["{$touser['languageid']}"] = $plaintext_parser->parse($pagetext_orig, $foruminfo['forumid']);
}
$pagetext = $pagetext_cache["{$touser['languageid']}"];
if ($threadinfo['prefixid']) {
// need prefix in correct language
$threadinfo['prefix_plain'] = fetch_phrase("prefix_{$threadinfo['prefixid']}_title_plain", 'global', '', false, true, $touser['languageid'], false) . ' ';
} else {
$threadinfo['prefix_plain'] = '';
}
($hook = vBulletinHook::fetch_hook('newpost_notification_message')) ? eval($hook) : false;
eval(iif(empty($evalemail["{$touser['languageid']}"]), $evalemail["-1"], $evalemail["{$touser['languageid']}"]));
if ($touser['emailupdate'] == 4 and !empty($touser['icq'])) {
// instant notification by ICQ
$touser['email'] = $touser['icq'] . '@pager.icq.com';
}
vbmail($touser['email'], $subject, $message);
}
unset($plaintext_parser, $pagetext_cache);
$vbulletin->userinfo['username'] = $temp;
vbmail_end();
}
开发者ID:holandacz,项目名称:nb4,代码行数:101,代码来源:functions_newpost.php
示例3: foreach
foreach ($eventlist as $userid => $event) {
$usernames .= iif($usernames, ', ');
$usernames .= $userinfo["{$userid}"]['username'];
$reminderbits = '';
foreach ($event as $eventid => $hour) {
$eventinfo =& $eventcache["{$eventid}"];
eval(fetch_email_phrases('reminderbit', $userinfo["{$userid}"]['languageid']));
$reminderbits .= $message;
}
$username = unhtmlspecialchars($userinfo["{$userid}"]['username']);
eval(fetch_email_phrases('reminder', $userinfo["{$userid}"]['languageid']));
vbmail($userinfo["{$userid}"]['email'], $subject, $message, true);
if ($vbulletin->debug and VB_AREA == 'AdminCP') {
"<pre>";
echo $subject;
echo "</pre>";
echo "<pre>";
echo $message;
echo "</pre><br />";
}
}
vbmail_end();
if (!empty($usernames)) {
log_cron_action($usernames, $nextitem, 1);
}
/*======================================================================*\
|| ####################################################################
|| # Downloaded: 22:41, Fri Oct 10th 2008
|| # CVS: $RCSfile$ - $Revision: 15604 $
|| ####################################################################
\*======================================================================*/
开发者ID:holandacz,项目名称:nb4,代码行数:31,代码来源:reminder.php
示例4: post_save_each
//.........这里部分代码省略.........
continue;
}
else if (
!$touser['blogmoderatorid']
AND
!($touser['permissions']['adminpermissions'] & $this->registry->bf_ugp_adminpermissions['cancontrolpanel'])
AND
!($touser['permissions']['adminpermissions'] & $this->registry->bf_ugp_adminpermissions['ismoderator'])
AND
(!$userinfo['ignore_canviewmyblog'] OR !$touser['ignoreid'])
AND
(!$userinfo['buddy_canviewmyblog'] OR !$touser['buddyid'])
AND
(!$userinfo['member_canviewmyblog'] OR (!$userinfo['buddy_canviewmyblog'] AND $touser['budyid']) OR (!$userinfo['ignore_canviewmyblog'] AND $touser['ignoreid']))
AND
!is_member_of_blog($touser, $userinfo)
)
{
continue;
}
$touser['username'] = unhtmlspecialchars($touser['username']);
$touser['languageid'] = iif($touser['languageid'] == 0, $this->registry->options['languageid'], $touser['languageid']);
$touser['auth'] = md5($touser['userid'] . $touser['blogsubscribeuserid'] . $touser['salt'] . COOKIE_SALT);
if (empty($evalemail))
{
$email_texts = $this->dbobject->query_read_slave("
SELECT text, languageid, fieldname
FROM " . TABLE_PREFIX . "phrase
WHERE fieldname IN ('emailsubject', 'emailbody') AND varname = 'blog_user_notify'
");
while ($email_text = $this->dbobject->fetch_array($email_texts))
{
$emails["$email_text[languageid]"]["$email_text[fieldname]"] = $email_text['text'];
}
require_once(DIR . '/includes/functions_misc.php');
foreach ($emails AS $languageid => $email_text)
{
// lets cycle through our array of notify phrases
$text_message = str_replace("\\'", "'", addslashes(iif(empty($email_text['emailbody']), $emails['-1']['emailbody'], $email_text['emailbody'])));
$text_message = replace_template_variables($text_message);
$text_subject = str_replace("\\'", "'", addslashes(iif(empty($email_text['emailsubject']), $emails['-1']['emailsubject'], $email_text['emailsubject'])));
$text_subject = replace_template_variables($text_subject);
$evalemail["$languageid"] = '
$message = "' . $text_message . '";
$subject = "' . $text_subject . '";
';
}
}
// parse the page text into plain text, taking selected language into account
if (!isset($pagetext_cache["$touser[languageid]"]))
{
$plaintext_parser->set_parsing_language($touser['languageid']);
$pagetext_cache["$touser[languageid]"] = $plaintext_parser->parse($pagetext_orig);
}
$pagetext = $pagetext_cache["$touser[languageid]"];
($hook = vBulletinHook::fetch_hook('blog_user_notification_message')) ? eval($hook) : false;
eval(iif(empty($evalemail["$touser[languageid]"]), $evalemail["-1"], $evalemail["$touser[languageid]"]));
vbmail($touser['email'], $subject, $message);
}
unset($plaintext_parser, $pagetext_cache);
vbmail_end();
}
$this->post_save_each_blogtext($doquery);
if ($this->fetch_field('dateline') <= TIMENOW)
{
$this->insert_dupehash($this->fetch_field('blogid'));
}
if ($this->condition AND $this->info['emailupdate'] == 'none' AND ($userid != $this->registry->userinfo['userid'] OR ($userid == $this->registry->userinfo['userid'] AND $this->existing['entrysubscribed'])))
{
$this->dbobject->query_write("
DELETE FROM " . TABLE_PREFIX . "blog_subscribeentry
WHERE blogid = $blogid AND userid = $userid
");
}
else if ($this->info['emailupdate'] == 'email' OR $this->info['emailupdate'] == 'usercp')
{
$this->dbobject->query_write("
REPLACE INTO " . TABLE_PREFIX . "blog_subscribeentry
(blogid, dateline, type, userid)
VALUES
($blogid, " . TIMENOW . ", '" . $this->info['emailupdate'] . "', $userid)
");
}
($hook = vBulletinHook::fetch_hook('blog_fpdata_postsave')) ? eval($hook) : false;
}
开发者ID:hungnv0789,项目名称:vhtm,代码行数:101,代码来源:class_dm_blog.php
示例5: exec_send_sg_notification
/**
* Sends email notifications for discussions.
*
* @param int $discussion - The discussion being updated
* @param int $messageid - Id of the message that triggered the update
* @param string $postusername - Optional username displayed on post
*/
function exec_send_sg_notification($discussionid, $gmid = false, $postusername = false)
{
global $vbulletin;
if (!$vbulletin->options['enableemail']) {
return;
}
$discussion = fetch_socialdiscussioninfo($discussionid);
// if there are no subscribers, no need to send notifications
if (!$discussion['subscribers']) {
return;
}
// if the discussion is moderated or deleted, don't send notification
if ('deleted' == $discussion['state'] or 'moderation' == $discussion['state']) {
return;
}
$group = fetch_socialgroupinfo($discussion['groupid']);
if (!$gmid) {
// get last gmid from discussion
$gmid = $vbulletin->db->query_first("\n\t\t\tSELECT MAX(gmid) AS gmid\n\t\t\tFROM " . TABLE_PREFIX . "groupmessage AS groupmessage\n\t\t\tWHERE discussionid = {$discussion['discussionid']}\n\t\t\t\tAND state = 'visible'\n\t\t");
$gmid = $gmid['gmid'];
}
// get message details
$gmessage = fetch_groupmessageinfo($gmid);
if (!$gmessage) {
return;
}
// get post time of previous message - if a user hasn't been active since then we won't resend a notification
$lastposttime = ($lastposttime = $vbulletin->db->query_first("\n\t\t\tSELECT MAX(dateline) AS dateline\n\t\t\tFROM " . TABLE_PREFIX . "groupmessage AS groupmessage\n\t\t\tWHERE discussionid = {$discussion['discussionid']}\n\t\t\t\tAND dateline < {$gmessage['dateline']}\n\t\t\t\tAND state = 'visible'\n\t")) ? $lastposttime['dateline'] : $gmessage['dateline'];
$discussion['title'] = unhtmlspecialchars($discussion['title']);
$group['name'] = unhtmlspecialchars($group['name']);
// temporarily use postusername in userinfo
if (!$postusername) {
// get current user name if user exists
if ($gmessage['postuserid'] and $userinfo = fetch_userinfo($gmessage['postuserid'])) {
$postusername = $userinfo['username'];
} else {
$postusername = $gmessage['postusername'];
}
}
$postusername = unhtmlspecialchars($postusername);
$userid = $gmessage['postuserid'];
($hook = vBulletinHook::fetch_hook('newpost_sg_notification_start')) ? eval($hook) : false;
$useremails = $vbulletin->db->query_read_slave("\n\t\tSELECT user.*, subscribediscussion.emailupdate, subscribediscussion.subscribediscussionid, IF(socialgroupmember.userid IS NOT NULL,1,0) ismember\n\t\tFROM " . TABLE_PREFIX . "subscribediscussion AS subscribediscussion\n\t\tINNER JOIN " . TABLE_PREFIX . "user AS user ON (subscribediscussion.userid = user.userid)\n\t\tLEFT JOIN " . TABLE_PREFIX . "usergroup AS usergroup ON (usergroup.usergroupid = user.usergroupid)\n\t\tLEFT JOIN " . TABLE_PREFIX . "usertextfield AS usertextfield ON (usertextfield.userid = user.userid)\n\t\tLEFT JOIN " . TABLE_PREFIX . "socialgroupmember AS socialgroupmember ON (socialgroupmember.userid = user.userid AND socialgroupmember.groupid = {$group['groupid']})\n\t\tWHERE subscribediscussion.discussionid = {$discussion['discussionid']}\n\t\t AND subscribediscussion.emailupdate = 1\n\t\t AND " . ($gmessage['postuserid'] ? " CONCAT(' ', IF(usertextfield.ignorelist IS NULL, '', usertextfield.ignorelist), ' ') NOT LIKE ' " . intval($userid) . " '" : '') . "\n\t\t AND user.usergroupid <> 3\n\t\t AND user.userid <> " . intval($userid) . "\n\t\t AND user.lastactivity >= " . intval($lastposttime) . "\n\t\t AND (usergroup.genericoptions & " . $vbulletin->bf_ugp_genericoptions['isnotbannedgroup'] . ")\n\t");
vbmail_start();
// parser for plaintexting the message pagetext
require_once DIR . '/includes/class_bbcode_alt.php';
$plaintext_parser =& new vB_BbCodeParser_PlainText($vbulletin, fetch_tag_list());
$pagetext_cache = array();
// used to cache the results per languageid for speed
$evalemail = array();
while ($touser = $vbulletin->db->fetch_array($useremails)) {
// check user can view discussion
$permissions = cache_permissions($touser, false);
if (!($vbulletin->usergroupcache["{$touser['usergroupid']}"]['genericoptions'] & $vbulletin->bf_ugp_genericoptions['isnotbannedgroup']) or !($permissions['forumpermissions'] & $vbulletin->bf_ugp_forumpermissions['canview']) or !($permissions['socialgrouppermissions'] & $vbulletin->bf_ugp_socialgrouppermissions['canviewgroups']) or $group['options'] & $vbulletin->bf_misc_socialgroupoptions['join_to_view'] and !$touser['ismember'] and !($permissions['socialgrouppermissions'] & $vbulletin->bf_ugp_socialgrouppermissions['canalwayscreatediscussion']) and !($permissions['socialgrouppermissions'] & $vbulletin->bf_ugp_socialgrouppermissions['canalwayspostmessage'])) {
continue;
}
$touser['username'] = unhtmlspecialchars($touser['username']);
$touser['languageid'] = iif($touser['languageid'] == 0, $vbulletin->options['languageid'], $touser['languageid']);
$touser['auth'] = md5($touser['userid'] . $touser['subscribediscussionid'] . $touser['salt'] . COOKIE_SALT);
if (empty($evalemail)) {
$email_texts = $vbulletin->db->query_read_slave("\n\t\t\t\tSELECT text, languageid, fieldname\n\t\t\t\tFROM " . TABLE_PREFIX . "phrase\n\t\t\t\tWHERE fieldname IN ('emailsubject', 'emailbody') AND varname = 'notify_discussion'\n\t\t\t");
while ($email_text = $vbulletin->db->fetch_array($email_texts)) {
$emails["{$email_text['languageid']}"]["{$email_text['fieldname']}"] = $email_text['text'];
}
require_once DIR . '/includes/functions_misc.php';
foreach ($emails as $languageid => $email_text) {
// lets cycle through our array of notify phrases
$text_message = str_replace("\\'", "'", addslashes(iif(empty($email_text['emailbody']), $emails['-1']['emailbody'], $email_text['emailbody'])));
$text_message = replace_template_variables($text_message);
$text_subject = str_replace("\\'", "'", addslashes(iif(empty($email_text['emailsubject']), $emails['-1']['emailsubject'], $email_text['emailsubject'])));
$text_subject = replace_template_variables($text_subject);
$evalemail["{$languageid}"] = '
$message = "' . $text_message . '";
$subject = "' . $text_subject . '";
';
}
}
// parse the page text into plain text, taking selected language into account
if (!isset($pagetext_cache["{$touser['languageid']}"])) {
$plaintext_parser->set_parsing_language($touser['languageid']);
$pagetext_cache["{$touser['languageid']}"] = $plaintext_parser->parse($gmessage['pagetext']);
}
$pagetext = $pagetext_cache["{$touser['languageid']}"];
($hook = vBulletinHook::fetch_hook('new_sg_message_notification_message')) ? eval($hook) : false;
eval(iif(empty($evalemail["{$touser['languageid']}"]), $evalemail["-1"], $evalemail["{$touser['languageid']}"]));
vbmail($touser['email'], $subject, $message);
}
$vbulletin->db->free_result($useremails);
unset($plaintext_parser, $pagetext_cache);
vbmail_end();
}
开发者ID:benyamin20,项目名称:vbregistration,代码行数:98,代码来源:functions_socialgroup.php
示例6: exec_digest
//.........这里部分代码省略.........
$forum['username'] = unhtmlspecialchars($forum['username']);
$forum['title_clean'] = unhtmlspecialchars($forum['title_clean']);
$forum['auth'] = md5($forum['userid'] . $forum['subscribeforumid'] . $forum['salt'] . COOKIE_SALT);
$threads = $vbulletin->db->query_read_slave("\n\t\t\tSELECT forum.title_clean AS forumtitle, thread.threadid, thread.title, thread.prefixid,\n\t\t\t\tthread.dateline, thread.forumid, thread.lastpost, pollid, open, thread.replycount,\n\t\t\t\tpostusername, postuserid, thread.lastposter, thread.dateline, views\n\t\t\tFROM " . TABLE_PREFIX . "forum AS forum\n\t\t\tINNER JOIN " . TABLE_PREFIX . "thread AS thread USING(forumid)\n\t\t\tWHERE FIND_IN_SET('" . intval($forum['forumid']) . "', forum.parentlist) AND\n\t\t\t\tthread.lastpost > " . intval($lastdate) . " AND\n\t\t\t\tthread.visible = 1\n\t\t");
while ($thread = $vbulletin->db->fetch_array($threads)) {
if ($thread['postuserid'] != $forum['userid'] and in_array($thread['postuserid'], $coventry)) {
continue;
}
$userperms = fetch_permissions($thread['forumid'], $forum['userid'], $forum);
// allow those without canviewthreads to subscribe/receive forum updates as they contain not post content
if (!($userperms & $vbulletin->bf_ugp_forumpermissions['canview']) or $thread['postuserid'] != $forum['userid'] and !($userperms & $vbulletin->bf_ugp_forumpermissions['canviewothers'])) {
continue;
}
$thread['forumtitle'] = unhtmlspecialchars($thread['forumtitle']);
$thread['lastreplydate'] = vbdate($forum['lang_dateoverride'] ? $forum['lang_dateoverride'] : $vbulletin->options['default_dateformat'], $thread['lastpost'], false, true, true, false, $userinfo);
$thread['lastreplytime'] = vbdate($forum['lang_timeoverride'] ? $forum['lang_timeoverride'] : $vbulletin->options['default_timeformat'], $thread['lastpost'], false, true, true, false, $userinfo);
$thread['title'] = unhtmlspecialchars($thread['title']);
$thread['postusername'] = unhtmlspecialchars($thread['postusername']);
$thread['lastposter'] = unhtmlspecialchars($thread['lastposter']);
if ($thread['prefixid']) {
// need prefix in correct language
$thread['prefix_plain'] = fetch_phrase("prefix_{$thread['prefixid']}_title_plain", 'global', '', false, true, $forum['languageid'], false) . ' ';
} else {
$thread['prefix_plain'] = '';
}
$threadlink = fetch_seo_url('thread|nosession|bburl', array('threadid' => $thread['threadid'], 'title' => htmlspecialchars_uni($thread['title'])));
($hook = vBulletinHook::fetch_hook('digest_forum_thread')) ? eval($hook) : false;
eval(fetch_email_phrases('digestthreadbit', $forum['languageid']));
if ($thread['dateline'] > $lastdate) {
// new thread
$newthreads++;
$newthreadbits .= $message;
} else {
$updatedthreads++;
$updatedthreadbits .= $message;
}
}
($hook = vBulletinHook::fetch_hook('digest_forum_process')) ? eval($hook) : false;
if (!empty($newthreads) or !empty($updatedthreadbits)) {
// make email
// magic vars used by the phrase eval
$forumlink = fetch_seo_url('forum|nosession|bburl', $forum);
$unsubscribelink = fetch_seo_url('subscription|nosession|bburl|js', array(), array('do' => 'removesubscription', 'type' => 'forum', 'subscriptionid' => $forum['subscribeforumid'], 'auth' => $forum['auth']));
eval(fetch_email_phrases('digestforum', $forum['languageid']));
vbmail($forum['email'], $subject, $message);
}
}
// ******* Social Group Digests **********
if ($vbulletin->options['socnet'] & $vbulletin->bf_misc_socnet['enable_groups']) {
require_once DIR . '/includes/functions_socialgroup.php';
$groups = $vbulletin->db->query_read_slave("\n\t\t\tSELECT user.userid, user.salt, user.username, user.email, user.languageid, user.usergroupid, user.membergroupids,\n\t\t\t\tuser.timezoneoffset, IF(user.options & " . $vbulletin->bf_misc_useroptions['dstonoff'] . ", 1, 0) AS dstonoff,\n\t\t\t\tIF(user.options & " . $vbulletin->bf_misc_useroptions['hasaccessmask'] . ", 1, 0) AS hasaccessmask,\n\t\t\t\tsocialgroup.groupid, socialgroup.name, socialgroup.options, socialgroupmember.type AS membertype, \n\t\t\t\tlanguage.dateoverride AS lang_dateoverride, language.timeoverride AS lang_timeoverride, language.locale AS lang_locale\n\t\t\tFROM " . TABLE_PREFIX . "subscribegroup AS subscribegroup\n\t\t\tINNER JOIN " . TABLE_PREFIX . "socialgroup AS socialgroup ON (socialgroup.groupid = subscribegroup.groupid)\n\t\t\tINNER JOIN " . TABLE_PREFIX . "user AS user ON (user.userid = subscribegroup.userid)\n\t\t\tLEFT JOIN " . TABLE_PREFIX . "socialgroupmember AS socialgroupmember ON\n\t\t\t\t(socialgroupmember.userid = user.userid AND socialgroupmember.groupid = socialgroup.groupid)\n\t\t\tLEFT JOIN " . TABLE_PREFIX . "usergroup AS usergroup ON (usergroup.usergroupid = user.usergroupid)\n\t\t\tLEFT JOIN " . TABLE_PREFIX . "language AS language ON (language.languageid = IF(user.languageid = 0, " . intval($vbulletin->options['languageid']) . ", user.languageid))\n\t\t\tWHERE subscribegroup.emailupdate = '" . ($type == 2 ? 'daily' : 'weekly') . "' AND\n\t\t\t\tsocialgroup.lastpost > " . intval($lastdate) . " AND\n\t\t\t\tuser.usergroupid <> 3 AND\n\t\t\t\t(usergroup.genericoptions & " . $vbulletin->bf_ugp_genericoptions['isnotbannedgroup'] . ")\n\t\t");
while ($group = $vbulletin->db->fetch_array($groups)) {
$userperms = cache_permissions($group, false);
if (!($userperms['forumpermissions'] & $vbulletin->bf_ugp_forumpermissions['canview']) or !($userperms['socialgrouppermissions'] & $vbulletin->bf_ugp_socialgrouppermissions['canviewgroups'])) {
continue;
}
if ($group['options'] & $vbulletin->bf_misc_socialgroupoptions['join_to_view'] and $vbulletin->options['sg_allow_join_to_view']) {
if ($group['membertype'] != 'member' and !($userperms['socialgrouppermissions'] & $vbulletin->bf_ugp_socialgrouppermissions['canalwayspostmessage']) and !($userperms['socialgrouppermissions'] & $vbulletin->bf_ugp_socialgrouppermissions['canalwascreatediscussion'])) {
continue;
}
}
$userinfo = array('lang_locale' => $group['lang_locale'], 'dstonoff' => $group['dstonoff'], 'timezoneoffset' => $group['timezoneoffset']);
$new_discussion_bits = '';
$new_discussions = 0;
$updated_discussion_bits = '';
$updated_discussions = 0;
$group['username'] = unhtmlspecialchars($group['username']);
$group['name'] = unhtmlspecialchars($group['name']);
$discussions = $vbulletin->db->query_read_slave("\n\t\t\t\tSELECT discussion.*, firstmessage.dateline,\n\t\t\t\t\tfirstmessage.title, firstmessage.postuserid, firstmessage.postusername\n\t\t\t\tFROM " . TABLE_PREFIX . "discussion AS discussion\n\t\t\t\tINNER JOIN " . TABLE_PREFIX . "groupmessage AS firstmessage ON\n\t\t\t\t\t(firstmessage.gmid = discussion.firstpostid)\n\t\t\t\tWHERE discussion.groupid = {$group['groupid']}\n\t\t\t\t\tAND discussion.lastpost > " . intval($lastdate) . "\n\t\t\t\t\tAND firstmessage.state = 'visible'\n\t\t\t");
while ($discussion = $vbulletin->db->fetch_array($discussions)) {
$discussion['lastreplydate'] = vbdate($group['lang_dateoverride'] ? $group['lang_dateoverride'] : $vbulletin->options['default_dateformat'], $discussion['lastpost'], false, true, true, false, $userinfo);
$discussion['lastreplytime'] = vbdate($group['lang_timeoverride'] ? $group['lang_timeoverride'] : $vbulletin->options['default_timeformat'], $discussion['lastpost'], false, true, true, false, $userinfo);
$discussion['title'] = unhtmlspecialchars($discussion['title']);
$discussion['postusername'] = unhtmlspecialchars($discussion['postusername']);
$discussion['lastposter'] = unhtmlspecialchars($discussion['lastposter']);
($hook = vBulletinHook::fetch_hook('digest_group_discussion')) ? eval($hook) : false;
//magic variables that will be picked up by the phrase eval
$discussionlink = fetch_seo_url('groupdiscussion', $discussion);
eval(fetch_email_phrases('digestgroupbit', $group['languageid']));
if ($discussion['dateline'] > $lastdate) {
// new discussion
$new_discussions++;
$new_discussion_bits .= $message;
} else {
$updated_discussions++;
$updated_discussion_bits .= $message;
}
}
($hook = vBulletinHook::fetch_hook('digest_group_process')) ? eval($hook) : false;
if (!empty($new_discussion_bits) or !empty($updated_discussion_bits)) {
//magic variables that will be picked up by the phrase eval
$grouplink = fetch_seo_url('group|nosession|bburl', $group);
// make email
eval(fetch_email_phrases('digestgroup', $group['languageid']));
vbmail($group['email'], $subject, $message);
}
}
}
vbmail_end();
}
开发者ID:0hyeah,项目名称:yurivn,代码行数:101,代码来源:functions_digest.php
示例7: exec_digest
//.........这里部分代码省略.........
// get new threads
$threads = $vbulletin->db->query_read_slave("\n\t\tSELECT\n\t\tuser.userid, user.salt, user.username, user.email, user.languageid, user.usergroupid, user.membergroupids,\n\t\t\tuser.timezoneoffset, IF(user.options & " . $vbulletin->bf_misc_useroptions['dstonoff'] . ", 1, 0) AS dstonoff,\n\t\t\tIF(user.options & " . $vbulletin->bf_misc_useroptions['hasaccessmask'] . ", 1, 0) AS hasaccessmask,\n\t\tthread.threadid, thread.title, thread.prefixid, thread.dateline, thread.forumid, thread.lastpost, pollid,\n\t\topen, replycount, postusername, postuserid, lastposter, thread.dateline, views, subscribethreadid,\n\t\t\tlanguage.dateoverride AS lang_dateoverride, language.timeoverride AS lang_timeoverride, language.locale AS lang_locale\n\t\tFROM " . TABLE_PREFIX . "subscribethread AS subscribethread\n\t\tINNER JOIN " . TABLE_PREFIX . "thread AS thread ON (thread.threadid = subscribethread.threadid)\n\t\tINNER JOIN " . TABLE_PREFIX . "user AS user ON (user.userid = subscribethread.userid)\n\t\tLEFT JOIN " . TABLE_PREFIX . "usergroup AS usergroup ON (usergroup.usergroupid = user.usergroupid)\n\t\tLEFT JOIN " . TABLE_PREFIX . "language AS language ON (language.languageid = IF(user.languageid = 0, " . intval($vbulletin->options['languageid']) . ", user.languageid))\n\t\tWHERE subscribethread.emailupdate = " . intval($type) . " AND\n\t\t\tthread.lastpost > " . intval($lastdate) . " AND\n\t\t\tthread.visible = 1 AND\n\t\t\tuser.usergroupid <> 3 AND\n\t\t\t(usergroup.genericoptions & " . $vbulletin->bf_ugp_genericoptions['isnotbannedgroup'] . ")\n\t");
while ($thread = $vbulletin->db->fetch_array($threads)) {
$postbits = '';
$userperms = fetch_permissions($thread['forumid'], $thread['userid'], $thread);
if (!($userperms & $vbulletin->bf_ugp_forumpermissions['canview']) or !($userperms & $vbulletin->bf_ugp_forumpermissions['canviewthreads']) or $thread['postuserid'] != $thread['userid'] and !($userperms & $vbulletin->bf_ugp_forumpermissions['canviewothers'])) {
continue;
}
$userinfo = array('lang_locale' => $thread['lang_locale'], 'dstonoff' => $thread['dstonoff'], 'timezoneoffset' => $thread['timezoneoffset']);
$thread['lastreplydate'] = vbdate($thread['lang_dateoverride'] ? $thread['lang_dateoverride'] : $vbulletin->options['default_dateformat'], $thread['lastpost'], false, true, true, false, $userinfo);
$thread['lastreplytime'] = vbdate($thread['lang_timeoverride'] ? $thread['lang_timeoverride'] : $vbulletin->options['default_timeformat'], $thread['lastpost'], false, true, true, false, $userinfo);
$thread['title'] = unhtmlspecialchars($thread['title']);
$thread['username'] = unhtmlspecialchars($thread['username']);
$thread['postusername'] = unhtmlspecialchars($thread['postusername']);
$thread['lastposter'] = unhtmlspecialchars($thread['lastposter']);
$thread['newposts'] = 0;
$thread['auth'] = md5($thread['userid'] . $thread['subscribethreadid'] . $thread['salt'] . COOKIE_SALT);
if ($thread['prefixid']) {
// need prefix in correct language
$thread['prefix_plain'] = fetch_phrase("prefix_{$thread['prefixid']}_title_plain", 'global', '', false, true, $thread['languageid'], false) . ' ';
} else {
$thread['prefix_plain'] = '';
}
// get posts
$posts = $vbulletin->db->query_read_slave("SELECT\n\t\t\tpost.*,IFNULL(user.username,post.username) AS postusername,\n\t\t\tuser.*,attachment.filename\n\t\t\tFROM " . TABLE_PREFIX . "post AS post\n\t\t\tLEFT JOIN " . TABLE_PREFIX . "user AS user ON (user.userid = post.userid)\n\t\t\tLEFT JOIN " . TABLE_PREFIX . "attachment AS attachment ON (attachment.postid = post.postid)\n\t\t\tWHERE threadid = " . intval($thread['threadid']) . " AND\n\t\t\t\tpost.visible = 1 AND\n\t\t\t\tuser.usergroupid <> 3 AND\n\t\t\t\tpost.dateline > " . intval($lastdate) . "\n\t\t\tORDER BY post.dateline\n\t\t");
// compile
$haveothers = false;
while ($post = $vbulletin->db->fetch_array($posts)) {
if ($post['userid'] != $thread['userid']) {
$haveothers = true;
}
$thread['newposts']++;
$post['postdate'] = vbdate($thread['lang_dateoverride'] ? $thread['lang_dateoverride'] : $vbulletin->options['default_dateformat'], $post['dateline'], false, true, true, false, $userinfo);
$post['posttime'] = vbdate($thread['lang_timeoverride'] ? $thread['lang_timeoverride'] : $vbulletin->options['default_timeformat'], $post['dateline'], false, true, true, false, $userinfo);
$post['postusername'] = unhtmlspecialchars($post['postusername']);
$plaintext_parser->set_parsing_language($thread['languageid']);
$post['pagetext'] = $plaintext_parser->parse($post['pagetext'], $thread['forumid']);
($hook = vBulletinHook::fetch_hook('digest_thread_post')) ? eval($hook) : false;
eval(fetch_email_phrases('digestpostbit', $thread['languageid']));
$postbits .= $message;
}
($hook = vBulletinHook::fetch_hook('digest_thread_process')) ? eval($hook) : false;
// Don't send an update if the subscriber is the only one who posted in the thread.
if ($haveothers) {
// make email
eval(fetch_email_phrases('digestthread', $thread['languageid']));
vbmail($thread['email'], $subject, $message);
}
}
unset($plaintext_parser);
// get new forums
$forums = $vbulletin->db->query_read_slave("\n\t\tSELECT user.userid, user.salt, user.username, user.email, user.languageid, user.usergroupid, user.membergroupids,\n\t\t\tuser.timezoneoffset, IF(user.options & " . $vbulletin->bf_misc_useroptions['dstonoff'] . ", 1, 0) AS dstonoff,\n\t\t\tIF(user.options & " . $vbulletin->bf_misc_useroptions['hasaccessmask'] . ", 1, 0) AS hasaccessmask,\n\t\t\tforum.forumid, forum.title_clean, subscribeforum.subscribeforumid,\n\t\t\tlanguage.dateoverride AS lang_dateoverride, language.timeoverride AS lang_timeoverride, language.locale AS lang_locale\n\t\tFROM " . TABLE_PREFIX . "subscribeforum AS subscribeforum\n\t\tINNER JOIN " . TABLE_PREFIX . "forum AS forum ON (forum.forumid = subscribeforum.forumid)\n\t\tINNER JOIN " . TABLE_PREFIX . "user AS user ON (user.userid = subscribeforum.userid)\n\t\tLEFT JOIN " . TABLE_PREFIX . "usergroup AS usergroup ON (usergroup.usergroupid = user.usergroupid)\n\t\tLEFT JOIN " . TABLE_PREFIX . "language AS language ON (language.languageid = IF(user.languageid = 0, " . intval($vbulletin->options['languageid']) . ", user.languageid))\n\t\tWHERE subscribeforum.emailupdate = " . intval($type) . " AND\n\t\t\tforum.lastpost > " . intval($lastdate) . " AND\n\t\t\tuser.usergroupid <> 3 AND\n\t\t\t(usergroup.genericoptions & " . $vbulletin->bf_ugp_genericoptions['isnotbannedgroup'] . ")\n\t");
while ($forum = $vbulletin->db->fetch_array($forums)) {
$userinfo = array('lang_locale' => $forum['lang_locale'], 'dstonoff' => $forum['dstonoff'], 'timezoneoffset' => $forum['timezoneoffset']);
$newthreadbits = '';
$newthreads = 0;
$updatedthreadbits = '';
$updatedthreads = 0;
$forum['username'] = unhtmlspecialchars($forum['username']);
$forum['title_clean'] = unhtmlspecialchars($forum['title_clean']);
$forum['auth'] = md5($forum['userid'] . $forum['subscribeforumid'] . $forum['salt'] . COOKIE_SALT);
$threads = $vbulletin->db->query_read_slave("\n\t\t\tSELECT forum.title_clean AS forumtitle, thread.threadid, thread.title, thread.prefixid,\n\t\t\t\tthread.dateline, thread.forumid, thread.lastpost, pollid, open, thread.replycount,\n\t\t\t\tpostusername, postuserid, thread.lastposter, thread.dateline, views\n\t\t\tFROM " . TABLE_PREFIX . "forum AS forum\n\t\t\tINNER JOIN " . TABLE_PREFIX . "thread AS thread USING(forumid)\n\t\t\tWHERE FIND_IN_SET('" . intval($forum['forumid']) . "', forum.parentlist) AND\n\t\t\t\tthread.lastpost > " . intval($lastdate) . " AND\n\t\t\t\tthread.visible = 1\n\t\t\t");
while ($thread = $vbulletin->db->fetch_array($threads)) {
$userperms = fetch_permissions($thread['forumid'], $forum['userid'], $forum);
// allow those without canviewthreads to subscribe/receive forum updates as they contain not post content
if (!($userperms & $vbulletin->bf_ugp_forumpermissions['canview']) or $thread['postuserid'] != $forum['userid'] and !($userperms & $vbulletin->bf_ugp_forumpermissions['canviewothers'])) {
continue;
}
$thread['forumtitle'] = unhtmlspecialchars($thread['forumtitle']);
$thread['lastreplydate'] = vbdate($forum['lang_dateoverride'] ? $forum['lang_dateoverride'] : $vbulletin->options['default_dateformat'], $thread['lastpost'], false, true, true, false, $userinfo);
$thread['lastreplytime'] = vbdate($forum['lang_timeoverride'] ? $forum['lang_timeoverride'] : $vbulletin->options['default_timeformat'], $thread['lastpost'], false, true, true, false, $userinfo);
$thread['title'] = unhtmlspecialchars($thread['title']);
$thread['postusername'] = unhtmlspecialchars($thread['postusername']);
$thread['lastposter'] = unhtmlspecialchars($thread['lastposter']);
if ($thread['prefixid']) {
// need prefix in correct language
$thread['prefix_plain'] = fetch_phrase("prefix_{$thread['prefixid']}_title_plain", 'global', '', false, true, $forum['languageid'], false) . ' ';
} else {
$thread['prefix_plain'] = '';
}
($hook = vBulletinHook::fetch_hook('digest_forum_thread')) ? eval($hook) : false;
eval(fetch_email_phrases('digestthreadbit', $forum['languageid']));
if ($thread['dateline'] > $lastdate) {
// new thread
$newthreads++;
$newthreadbits .= $message;
} else {
$updatedthreads++;
$updatedthreadbits .= $message;
}
}
($hook = vBulletinHook::fetch_hook('digest_forum_process')) ? eval($hook) : false;
if (!empty($newthreads) or !empty($updatedthreadbits)) {
// make email
eval(fetch_email_phrases('digestforum', $forum['languageid']));
vbmail($forum['email'], $subject, $message);
}
}
vbmail_end();
}
开发者ID:holandacz,项目名称:nb4,代码行数:101,代码来源:functions_digest.php
示例8: vbseo_sitemap_stat
function vbseo_sitemap_stat($stat, $email)
{
global $vbseo_vars, $vboptions;
$stat['txt'] = $vbseo_vars['txt'];
$logfname = VBSEO_DAT_FOLDER . time() . '.log';
$pf = fopen($logfname, 'w');
fwrite($pf, serialize($stat));
fclose($pf);
@chmod($logfname, 0666);
if (!$email) {
return;
}
$mailbody = "Hello!\n\nThe vBSEO Google/Yahoo Sitemap has been successfully generated for your vBulletin forums at:\n{$vboptions['bbtitle']} ({$vbseo_vars['bburl']})\n\nReport:\n============================\nClick the following link for your vBSEO Google/Yahoo Sitemap Report:\n{$vbseo_vars['bburl']}/vbseo_sitemap/\n\nSummary:\n============================\nForum Display: " . $stat['f'] . "\nShow Thread: " . $stat['t'] . "\nShow Post: " . $stat['p'] . "\nMember Profiles: " . $stat['m'] . "\nPoll Results: " . $stat['poll'] . "\nArchive: " . ($stat['af'] + $stat['at']) . "\n\nTotal Indexed URLs: " . $stat['urls_no_tot'] . "\nTotal Processing Time: " . number_format($stat['end'] - $stat['start'], 2) . " seconds\n\nGoogle ping: " . (isset($stat['ping']) ? $stat['ping'] ? 'Successful' : 'FAILED' : 'Disabled') . ".\nYahoo ping: " . (isset($stat['pingyahoo']) ? $stat['pingyahoo'] ? 'Successful' : 'FAILED' : 'Disabled') . ".\nAsk ping: " . (isset($stat['pingask']) ? $stat['pingask'] ? 'Successful' : 'FAILED' : 'Disabled') . ".\nMoreover ping: " . (isset($stat['pingmore']) ? $stat['pingmore'] ? 'Successful' : 'FAILED' : 'Disabled') . ".\nLive.com ping: " . (isset($stat['pinglive']) ? $stat['pinglive'] ? 'Successful' : 'FAILED' : 'Disabled') . ".\n\n============================\nvBSEO(TM) c 2005-2008 Crawlability, Inc.\nhttp://www.crawlability.com/vbseo\nhttp://www.vbseo.com\n\n\nNote for vBSEO users: This version of the sitemap generator works with vBSEO 2.4.1 up.\nPlease download the most recent vBSEO here: http://www.vbseo.com/downloads/\n";
if (VBSEO_ON) {
$mailbody .= "\n\nFind out more out vBSEO - vBulletin Search Engine Optimization\n============================\n\nvBSEO is the definitive SEO enhancement for your vBulletin community forums!\n\nvBSEO makes it easier for search engines to crawl more of your valuable vBulletin content faster and more often giving you higher keyword relevancy.\n\nBy installing vBSEO for your vBulletin forums you should expect to:\n\n * Get more of your forum pages indexed in the major search engines\n * Get your pages indexed faster\n * Improve your keyword relevancy for all pages\n * Prevent possible duplicate content penalties\n\nThe result of installing vBSEO you should expect is:\n\n * Higher visitor to member conversion rate (i.e. gain more new members faster)\n * Get visitors who are more highly targeted to the content you provide\n * Increase the monthly revenues earned from your forums\n * Improve your chances of achieving big-board.com status\n\nvBulletin + vBSEO\n============================\nSerious forum admins choose vBSEO for increased search engine traffic!\nhttp://www.vbseo.com/purchase/\n";
}
if (function_exists('vbmail_start')) {
vbmail_start();
vbmail($email, 'vBSEO Google/Yahoo Sitemap Updated', $mailbody);
vbmail_end();
} else {
mail($email, 'vBSEO Google/Yahoo Sitemap Updated', $mailbody, "From: " . $email);
}
}
开发者ID:holandacz,项目名称:nb4,代码行数:24,代码来源:vbseo_sitemap_functions.php
示例9: vbseo_send_notification_pingback
function vbseo_send_notification_pingback($threadid, $postid, $vbseo_linkback_uri, $title, $message, $approve = 1, $sendtocp = 1)
{
global $vbulletin;
if (!$vbulletin) {
return;
}
if (!$vbulletin->options['enableemail']) {
return;
}
@define('VBSEO_PREPROCESSED', true);
$threadinfo = fetch_threadinfo($threadid);
$foruminfo = fetch_foruminfo($threadinfo['forumid']);
$threadinfo['title'] = unhtmlspecialchars($threadinfo['title']);
$foruminfo['title_clean'] = unhtmlsp
|
请发表评论