当前位置: 首页>>代码示例>>PHP>>正文


PHP isBlackListed函数代码示例

本文整理汇总了PHP中isBlackListed函数的典型用法代码示例。如果您正苦于以下问题:PHP isBlackListed函数的具体用法?PHP isBlackListed怎么用?PHP isBlackListed使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了isBlackListed函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: Sql_Insert_Id

     $userid = Sql_Insert_Id($tables['user'], 'id');
     ++$count_email_add;
     $some = 1;
     $history_entry = $GLOBALS['I18N']->get('Import of new subscriber');
     # add the attributes for this user
     foreach ($attributes as $attr => $value) {
         if (is_array($value)) {
             $value = implode(',', $value);
         }
         Sql_query(sprintf('replace into %s (attributeid,userid,value) values("%s","%s","%s")', $tables['user_attribute'], $attr, $userid, addslashes($value)));
     }
 }
 #add this user to the lists identified, execpt when found in the blacklist
 $addition = 0;
 $listoflists = '';
 $isBlackListed = isBlackListed($email);
 if (!$isBlackListed) {
     foreach ($importdata['importlists'] as $key => $listid) {
         $query = 'replace INTO ' . $tables['listuser'] . " (userid,listid,entered) values({$userid},{$listid},now())";
         $result = Sql_query($query);
         # if the affected rows is 2, the user was already subscribed
         $addition = $addition || Sql_Affected_Rows() == 1;
         if (!empty($importdata['listname'][$key])) {
             $listoflists .= '  * ' . $importdata['listname'][$key] . "\n";
         }
     }
     if ($addition) {
         ++$additional_emails;
     }
 } else {
     ## mark blacklisted, just in case ##17288
开发者ID:gillima,项目名称:phplist3,代码行数:31,代码来源:import1.php

示例2: Sql_query

}
##$subselect .= ' limit 500'; // just to test the progress meter
if ($list) {
    $result = Sql_query(sprintf('select * from
    %s where user.id = listuser.userid and listuser.listid = %d and %s >= "%s 00:00:00" and %s  <= "%s 23:59:59" %s
    ', $querytables, $list, $column, $fromdate, $column, $todate, $subselect));
} else {
    $result = Sql_query(sprintf('
    select * from %s where %s >= "%s 00:00:00" and %s  <= "%s 23:59:59" %s', $querytables, $column, $fromdate, $column, $todate, $subselect));
}
$todo = Sql_Affected_Rows();
$done = 0;
fwrite($exportfile, $GLOBALS['I18N']->get('List Membership') . $row_delim);
while ($user = Sql_fetch_array($result)) {
    ## re-verify the blacklist status
    if (empty($user['blacklisted']) && isBlackListed($user['email'])) {
        $user['blacklisted'] = 1;
        Sql_Query(sprintf('update %s set blacklisted = 1 where email = "%s"', $GLOBALS['tables']['user'], $user['email']));
    }
    set_time_limit(500);
    if ($done % 50 == 0) {
        print '<script type="text/javascript">
    var parentJQuery = window.parent.jQuery;
    parentJQuery("#progressbar").updateProgress("' . $done . ',' . $todo . '");
    </script>';
        flush();
    }
    ++$done;
    reset($_SESSION['export']['cols']);
    while (list($key, $val) = each($_SESSION['export']['cols'])) {
        fwrite($exportfile, strtr($user[$val], $col_delim, ',') . $col_delim);
开发者ID:gillima,项目名称:phplist3,代码行数:31,代码来源:export.php

示例3: Sql_Fetch_Row_Query

$email = $date = $uid = '';
if (isset($cline['e'])) {
    $email = $cline['e'];
}
if (isset($cline['u'])) {
    $uid = $cline['u'];
}
if (isset($cline['d'])) {
    $date = $cline['d'];
}
$emailQ = Sql_Fetch_Row_Query(sprintf('select email from %s where uniqid = "%s" or email = "%s"  order by email desc', $GLOBALS['tables']['user'], sql_escape($uid), sql_escape($email)));
$emailDB = $emailQ[0];
if (empty($emailDB) && empty($email)) {
    cl_output('FAIL');
    exit;
}
if (isBlackListed($emailDB)) {
    ## do this anyway, just to be sure
    Sql_Query(sprintf('update %s set blacklisted = 1 where email = "%s"', $GLOBALS['tables']['user'], $emailDB));
    cl_output('OK');
    exit;
}
if (!empty($emailDB)) {
    ## do this immediately
    Sql_Query(sprintf('update %s set blacklisted = 1 where email = "%s"', $GLOBALS['tables']['user'], $emailDB));
    addEmailToBlackList($emailDB, 'blacklisted due to spam complaints', $date);
} else {
    addEmailToBlackList($email, 'blacklisted due to spam complaints', $date);
}
cl_output('OK ' . $emailDB);
exit;
开发者ID:narareddy,项目名称:phplist3,代码行数:31,代码来源:blacklistemail.php

示例4: forwardPage


//.........这里部分代码省略.........
        if (strlen(strip_newlines($_REQUEST['personalNote'])) > FORWARD_PERSONAL_NOTE_SIZE || strlen($_REQUEST['personalNote']) > FORWARD_PERSONAL_NOTE_SIZE * 2) {
            $info .= '<BR />' . $GLOBALS['strForwardNoteLimitReached'];
            $ok = false;
        }
        $personalNote = strip_tags(htmlspecialchars_decode(stripslashes($_REQUEST['personalNote'])));
        $userdata['personalNote'] = $personalNote;
    }
    if ($userdata['id'] && $mid) {
        if ($ok && count($emails)) {
            ## All is well, send it
            require_once 'admin/sendemaillib.php';
            #0013845 Lead Ref Scheme
            if (FORWARD_FRIEND_COUNT_ATTRIBUTE) {
                $iCountFriends = FORWARD_FRIEND_COUNT_ATTRIBUTE;
            } else {
                $iCountFriends = 0;
            }
            if ($iCountFriends) {
                $nFriends = intval(UserAttributeValue($userdata['id'], $iCountFriends));
            }
            ## remember the lists for this message in order to notify only those admins
            ## that own them
            $messagelists = array();
            $messagelistsreq = Sql_Query(sprintf('select listid from %s where messageid = %d', $GLOBALS['tables']['listmessage'], $mid));
            while ($row = Sql_Fetch_Row($messagelistsreq)) {
                array_push($messagelists, $row[0]);
            }
            foreach ($emails as $index => $email) {
                #0011860: forward to friend, multiple emails
                $done = Sql_Fetch_Array_Query(sprintf('select user,status,time from %s where forward = "%s" and message = %d', $tables['user_message_forward'], $email, $mid));
                $info .= '<br />' . $email . ': ';
                if ($done['status'] === 'sent') {
                    $info .= $GLOBALS['strForwardAlreadyDone'];
                } elseif (isBlackListed($email)) {
                    $info .= $GLOBALS['strForwardBlacklistedEmail'];
                } else {
                    if (!TEST) {
                        # forward the message
                        # sendEmail will take care of blacklisting
                        ### CHECK $email vs $forwardemail
                        if (sendEmail($mid, $email, 'forwarded', $userdata['htmlemail'], array(), $userdata)) {
                            $info .= $GLOBALS['strForwardSuccessInfo'];
                            sendAdminCopy(s('Message Forwarded'), s('%s has forwarded message %d to %s', $userdata['email'], $mid, $email), $messagelists);
                            Sql_Query(sprintf('insert into %s (user,message,forward,status,time)
                 values(%d,%d,"%s","sent",now())', $tables['user_message_forward'], $userdata['id'], $mid, $email));
                            if ($iCountFriends) {
                                ++$nFriends;
                            }
                        } else {
                            $info .= $GLOBALS['strForwardFailInfo'];
                            sendAdminCopy(s('Message Forwarded'), s('%s tried forwarding message %d to %s but failed', $userdata['email'], $mid, $email), $messagelists);
                            Sql_Query(sprintf('insert into %s (user,message,forward,status,time)
                values(%d,%d,"%s","failed",now())', $tables['user_message_forward'], $userdata['id'], $mid, $email));
                            $ok = false;
                        }
                    }
                }
            }
            # foreach friend
            if ($iCountFriends) {
                saveUserAttribute($userdata['id'], $iCountFriends, array('name' => FORWARD_FRIEND_COUNT_ATTRIBUTE, 'value' => $nFriends));
            }
        }
        #ok & emails
    } else {
        # no valid sender
开发者ID:gillima,项目名称:phplist3,代码行数:67,代码来源:index.php

示例5: foreach

     $information_changed = 0;
     foreach ($current_data as $key => $val) {
         if (!is_numeric($key)) {
             if (isset($old_data[$key]) && $old_data[$key] != $val && $old_data[$key] && $key != 'password' && $key != 'modified') {
                 $information_changed = 1;
                 $history_entry .= "{$key} = {$val}\n*changed* from {$old_data[$key]}\n";
             }
         }
     }
     if (!$information_changed) {
         $history_entry .= "\nNo user details changed";
     }
     addUserHistory($user['systemvalues']['email'], 'Import by ' . adminName(), $history_entry);
 }
 #add this user to the lists identified, except when they are blacklisted
 $isBlackListed = isBlackListed($user['systemvalues']['email']);
 if (!$isBlackListed && is_array($_SESSION['lists'])) {
     reset($_SESSION['lists']);
     $addition = 0;
     $listoflists = '';
     while (list($key, $listid) = each($_SESSION['lists'])) {
         $query = 'replace INTO ' . $tables['listuser'] . " (userid,listid,entered) values({$userid},{$listid},now())";
         $result = Sql_query($query, 1);
         # if the affected rows is 2, the user was already subscribed
         $addition = $addition || Sql_Affected_Rows() == 1;
         $listoflists .= '  * ' . listName($key) . "\n";
         # $_SESSION["listname"][$key] . "\n";
     }
     if ($addition) {
         ++$count['list_add'];
     }
开发者ID:MarcelvC,项目名称:phplist3,代码行数:31,代码来源:import2.php

示例6: eregi_replace

 if (eregi("\\[email\\]", $thankyoupage, $regs)) {
     $thankyoupage = eregi_replace("\\[email\\]", $email, $thankyoupage);
 }
 $user_att = getUserAttributeValues($email);
 while (list($att_name, $att_value) = each($user_att)) {
     if (eregi("\\[" . $att_name . "\\]", $thankyoupage, $regs)) {
         $thankyoupage = eregi_replace("\\[" . $att_name . "\\]", $att_value, $thankyoupage);
     }
 }
 if (is_array($GLOBALS["plugins"])) {
     reset($GLOBALS["plugins"]);
     foreach ($GLOBALS["plugins"] as $name => $plugin) {
         $thankyoupage = $plugin->parseThankyou($id, $userid, $thankyoupage);
     }
 }
 $blacklisted = isBlackListed($email);
 if ($blacklisted) {
     $thankyoupage .= '<p>' . $GLOBALS["strYouAreBlacklisted"] . '</p>';
     return 1;
 }
 if ($sendrequest && $listsok) {
     #is_array($_POST["list"])) {
     if (sendMail($email, getConfig("subscribesubject:{$id}"), $subscribemessage, system_messageheaders($email), '', 1)) {
         sendAdminCopy("Lists subscription", "\n" . $email . " has subscribed\n\n{$history_entry}");
         addUserHistory($email, $history_subject, $history_entry);
         print $thankyoupage;
     } else {
         print '<h3>' . $strEmailFailed . '</h3>';
         if ($blacklisted) {
             print '<p>' . $GLOBALS["strYouAreBlacklisted"] . '</p>';
         }
开发者ID:TheReaCompany,项目名称:pooplog,代码行数:31,代码来源:subscribelib2.php

示例7: sendMail

 function sendMail($to, $subject, $message, $header = "", $parameters = "")
 {
     #    mail($to,$subject,$message);
     dbg("mail {$to} {$subject}");
     if (!$to) {
         logEvent("Error: empty To: in message with subject {$subject} to send");
         return 0;
     } elseif (!$subject) {
         logEvent("Error: empty Subject: in message to send to {$to}");
         return 0;
     }
     if (isBlackListed($to)) {
         logEvent("Error, {$to} is blacklisted, not sending");
         Sql_Query(sprintf('update %s set blacklisted = 1 where email = "%s"', $this->tables["user"], $to));
         addUserHistory($to, "Marked Blacklisted", "Found user in blacklist while trying to send an email, marked black listed");
         return 0;
     }
     $v = phpversion();
     $v = preg_replace("/\\-.*\$/", "", $v);
     $header .= "X-Mailer: webbler/phplist v" . VERSION . ' (http://www.phplist.com)' . "\n";
     $from_address = $this->getConfig("message_from_address");
     $from_name = $this->getConfig("message_from_name");
     if ($from_name) {
         $header .= "From: \"{$from_name}\" <{$from_address}>\n";
     } else {
         $header .= "From: {$from_address}\n";
     }
     $message_replyto_address = $this->getConfig("message_replyto_address");
     if ($message_replyto_address) {
         $header .= "Reply-To: {$message_replyto_address}\n";
     } else {
         $header .= "Reply-To: {$from_address}\n";
     }
     $v = VERSION;
     $v = ereg_replace("-dev", "", $v);
     $header .= "X-MessageID: systemmessage\n";
     if ($useremail) {
         $header .= "X-User: " . $useremail . "\n";
     }
     if ($this->message_envelope) {
         $header = rtrim($header);
         if ($header) {
             $header .= "\n";
         }
         $header .= "Errors-To: " . $this->message_envelope;
         if (!$parameters || !ereg("-f" . $this->message_envelope)) {
             $parameters = '-f' . $this->message_envelope;
         }
     }
     if (!ereg("dev", VERSION)) {
         if (mail($to, $subject, $message, $header, $parameters)) {
             return 1;
         } else {
             return mail($to, $subject, $message, $header);
         }
     } else {
         # send mails to one place when running a test version
         $message = "To: {$to}\n" . $message;
         if ($this->developer_email) {
             return mail($this->developer_email, $subject, $message, $header, $parameters);
         } else {
             print "Error: Running CVS version, but developer_email not set";
         }
     }
 }
开发者ID:dehvCurtis,项目名称:phplist,代码行数:65,代码来源:phplist.php

示例8: PageLinkButton

print '<div id="add-user-button">' . PageLinkButton('adduser', $GLOBALS['I18N']->get('Add a User')) . '</div>';
print '</div>';
$some = 0;
$ls = new WebblerListing(s('users'));
$ls->usePanel($paging);
if ($result) {
    while ($user = Sql_fetch_array($result)) {
        $some = 1;
        $ls->addElement($user['email'], PageURL2("user&amp;start={$start}&amp;id=" . $user['id'] . $find_url));
        $ls->setClass($user['email'], 'row1');
        ## we make one column with the subscriber status being "on" or "off"
        ## two columns are too confusing and really unnecessary
        # ON = confirmed &&  !blacklisted
        #    $ls->addColumn($user["email"], $GLOBALS['I18N']->get('confirmed'), $user["confirmed"] ? $GLOBALS["img_tick"] : $GLOBALS["img_cross"]);
        #   if (in_array("blacklist", $columns)) {
        $onblacklist = isBlackListed($user['email']);
        #    $ls->addColumn($user["email"], $GLOBALS['I18N']->get('bl l'), $onblacklist ? $GLOBALS["img_tick"] : $GLOBALS["img_cross"]);
        #  }
        if ($user['confirmed'] && !$onblacklist) {
            $ls_confirmed = $GLOBALS['img_tick'];
        } else {
            $ls_confirmed = $GLOBALS['img_cross'];
        }
        $ls_del = '';
        #    $ls->addColumn($user["email"], $GLOBALS['I18N']->get('del'), sprintf('<a href="%s" onclick="return deleteRec(\'%s\');">del</a>',PageUrl2('users'.$find_url), PageURL2("users&start=$start&delete=" .$user["id"])));
        if (isSuperUser()) {
            $ls_del = sprintf('<a href="javascript:deleteRec(\'%s\');" class="del">del</a>', PageURL2("users&start={$start}&find={$find}&findby={$findby}&delete=" . $user['id']));
        }
        /*    if (isset ($user['foreignkey'])) {
                    $ls->addColumn($user["email"], $GLOBALS['I18N']->get('key'), $user["foreignkey"]);
                  }
开发者ID:bramley,项目名称:phplist3,代码行数:31,代码来源:users.php

示例9: ucfirst

print '<div class="tabbed">';
print '<ul>';
print '<li><a href="#messages">' . ucfirst($GLOBALS['I18N']->get('Campaigns')) . '</a></li>';
if (count($bounces)) {
    print '<li><a href="#bounces">' . ucfirst($GLOBALS['I18N']->get('Bounces')) . '</a></li>';
}
print '<li><a href="#subscription">' . ucfirst($GLOBALS['I18N']->get('Subscription')) . '</a></li>';
print '</ul>';
print '<div id="messages">';
print $ls->display();
print '</div>';
print '<div id="bounces">';
print $bouncels->display();
print '</div>';
print '<div id="subscription">';
if (isBlackListed($user['email'])) {
    print '<h3>' . $GLOBALS['I18N']->get('subscriber is blacklisted since') . ' ';
    $blacklist_info = Sql_Fetch_Array_Query(sprintf('select * from %s where email = "%s"', $tables['user_blacklist'], $user['email']));
    print $blacklist_info['added'] . '</h3><br/>';
    print '';
    $isSpamReport = false;
    $ls = new WebblerListing($GLOBALS['I18N']->get('Blacklist info'));
    $req = Sql_Query(sprintf('select * from %s where email = "%s"', $tables['user_blacklist_data'], $user['email']));
    while ($row = Sql_Fetch_Array($req)) {
        $ls->addElement($row['name']);
        $isSpamReport = $isSpamReport || $row['data'] == 'blacklisted due to spam complaints';
        $ls->addColumn($row['name'], $GLOBALS['I18N']->get('value'), stripslashes($row['data']));
    }
    $ls->addElement('<!-- remove -->');
    if (!$isSpamReport) {
        $button = new ConfirmButton(htmlspecialchars($GLOBALS['I18N']->get('are you sure you want to delete this subscriber from the blacklist')) . '?\\n' . htmlspecialchars($GLOBALS['I18N']->get('it should only be done with explicit permission from this subscriber')), PageURL2("userhistory&unblacklist={$user['id']}&id={$user['id']}", 'button', s('remove subscriber from blacklist')), s('remove subscriber from blacklist'));
开发者ID:gillima,项目名称:phplist3,代码行数:31,代码来源:userhistory.php

示例10: foreach

     $information_changed = 0;
     foreach ($current_data as $key => $val) {
         if (!is_numeric($key)) {
             if (isset($old_data[$key]) && $old_data[$key] != $val && $old_data[$key] && $key != "password" && $key != "modified") {
                 $information_changed = 1;
                 $history_entry .= "{$key} = {$val}\n*changed* from {$old_data[$key]}\n";
             }
         }
     }
     if (!$information_changed) {
         $history_entry .= "\nNo user details changed";
     }
     addUserHistory($user["systemvalues"]["email"], "Import by " . adminName(), $history_entry);
 }
 #add this user to the lists identified, except when they are blacklisted
 $isBlackListed = isBlackListed($user["systemvalues"]["email"]);
 if (!$isBlackListed && is_array($_SESSION["lists"])) {
     reset($_SESSION["lists"]);
     $addition = 0;
     $listoflists = "";
     while (list($key, $listid) = each($_SESSION["lists"])) {
         $query = "replace INTO " . $tables["listuser"] . " (userid,listid,entered) values({$userid},{$listid},now())";
         $result = Sql_query($query, 1);
         # if the affected rows is 2, the user was already subscribed
         $addition = $addition || Sql_Affected_Rows() == 1;
         $listoflists .= "  * " . listName($key) . "\n";
         # $_SESSION["listname"][$key] . "\n";
     }
     if ($addition) {
         $count["list_add"]++;
     }
开发者ID:Gerberus,项目名称:phplist3,代码行数:31,代码来源:import2.php

示例11: ob_end_clean

<?php

ob_end_clean();
## blacklist an email from commandline
if (!function_exists('cl_output')) {
    function cl_output($message)
    {
        @ob_end_clean();
        print strip_tags($message) . "\n";
        $infostring = '';
        ob_start();
    }
}
$email = $cline['e'];
$uid = $cline['u'];
if (!empty($uid) && empty($email)) {
    $emailreq = Sql_Fetch_Row_Query(sprintf('select email from %s where uniqid = "%s"', $GLOBALS['tables']['user'], $uid));
    $email = $emailreq[0];
}
if (empty($email)) {
    cl_output('No email');
    exit;
}
if (isBlackListed($email)) {
    cl_output('Already blacklisted');
    exit;
}
addEmailToBlackList($email, 'blacklisted due to spam complaints');
cl_output($email . ' blacklisted');
exit;
开发者ID:alancohen,项目名称:alancohenexperience-com,代码行数:30,代码来源:blacklistemail.php

示例12: sendMail

 function sendMail($to, $subject, $message, $header = "", $parameters = "")
 {
     mail($to, $subject, $message);
     dbg("mail {$to} {$subject}");
     if (TEST) {
         return 1;
     }
     if (!$to) {
         logEvent("Error: empty To: in message with subject {$subject} to send");
         return 0;
     } elseif (!$subject) {
         logEvent("Error: empty Subject: in message to send to {$to}");
         return 0;
     }
     if (isBlackListed($to)) {
         logEvent("Error, {$to} is blacklisted, not sending");
         Sql_Query(sprintf('update %s set blacklisted = 1 where email = "%s"', $GLOBALS["tables"]["user"], $to));
         addUserHistory($to, "Marked Blacklisted", "Found user in blacklist while trying to send an email, marked black listed");
         return 0;
     }
     $v = phpversion();
     $v = preg_replace("/\\-.*\$/", "", $v);
     if ($GLOBALS["message_envelope"]) {
         $header = rtrim($header);
         if ($header) {
             $header .= "\n";
         }
         $header .= "Errors-To: " . $GLOBALS["message_envelope"];
         if (!$parameters || !ereg("-f" . $GLOBALS["message_envelope"], $parameters)) {
             $parameters = '-f' . $GLOBALS["message_envelope"];
         }
     }
     $header .= "X-Mailer: PHPlist v" . VERSION . ' (http://www.phplist.com)' . "\n";
     if (WORKAROUND_OUTLOOK_BUG) {
         $header = rtrim($header);
         if ($header) {
             $header .= "\n";
         }
         $header .= "X-Outlookbug-fixed: Yes";
         $message = preg_replace("/\r?\n/", "\r\n", $message);
     }
     if (!ereg("dev", VERSION)) {
         if ($v > "4.0.5" && !ini_get("safe_mode")) {
             if (mail($to, $subject, $message, $header, $parameters)) {
                 return 1;
             } else {
                 return mail($to, $subject, $message, $header);
             }
         } else {
             return mail($to, $subject, $message, $header);
         }
     } else {
         # send mails to one place when running a test version
         $message = "To: {$to}\n" . $message;
         if ($GLOBALS["developer_email"]) {
             return mail($GLOBALS["developer_email"], $subject, $message, $header, $parameters);
         } else {
             print "Error: Running CVS version, but developer_email not set";
         }
     }
 }
开发者ID:ber5ien,项目名称:www.jade-palace.co.uk,代码行数:61,代码来源:phplist.php

示例13: confirmPage

function confirmPage($id)
{
    global $tables, $envelope;
    if (!$_GET["uid"]) {
        FileNotFound();
    }
    $req = Sql_Query("select * from {$tables["user"]} where uniqid = \"" . $_GET["uid"] . "\"");
    $userdata = Sql_Fetch_Array($req);
    if ($userdata["id"]) {
        $blacklisted = isBlackListed($userdata["email"]);
        $html = '<ul>';
        $lists = '';
        Sql_Query("update {$tables["user"]} set confirmed = 1,blacklisted = 0 where id = " . $userdata["id"]);
        $req = Sql_Query(sprintf('select name,description from %s list, %s listuser where listuser.userid = %d and listuser.listid = list.id and list.active', $tables['list'], $tables['listuser'], $userdata['id']));
        if (!Sql_Affected_Rows()) {
            $lists = "\n * " . $GLOBALS["strNoLists"];
            $html .= '<li>' . $GLOBALS["strNoLists"] . '</li>';
        }
        while ($row = Sql_fetch_array($req)) {
            $lists .= "\n *" . stripslashes($row["name"]);
            $html .= '<li class="list">' . stripslashes($row["name"]) . '<div class="listdescription">' . stripslashes($row["description"]) . '</div></li>';
        }
        $html .= '</ul>';
        if ($blacklisted) {
            unBlackList($userdata['id']);
            addUserHistory($userdata["email"], "Confirmation", "User removed from Blacklist for manual confirmation of subscription");
        }
        addUserHistory($userdata["email"], "Confirmation", "Lists: {$lists}");
        $spage = $userdata["subscribepage"];
        $confirmationmessage = ereg_replace('\\[LISTS\\]', $lists, getUserConfig("confirmationmessage:{$spage}", $userdata["id"]));
        if (!TEST) {
            sendMail($userdata["email"], getConfig("confirmationsubject:{$spage}"), $confirmationmessage, system_messageheaders(), $envelope);
            $adminmessage = $userdata["email"] . " has confirmed their subscription";
            if ($blacklisted) {
                $adminmessage .= "\nUser has been removed from blacklist";
            }
            sendAdminCopy("List confirmation", $adminmessage);
            addSubscriberStatistics('confirmation', 1);
        }
        $info = $GLOBALS["strConfirmInfo"];
    } else {
        logEvent("Request for confirmation for invalid user ID: " . substr($_GET["uid"], 0, 150));
        $html .= 'Error: ' . $GLOBALS["strUserNotFound"];
        $info = $GLOBALS["strConfirmFailInfo"];
    }
    $data = PageData($id);
    if (isset($data['language_file']) && is_file(dirname(__FILE__) . '/texts/' . $data['language_file'])) {
        @(include dirname(__FILE__) . '/texts/' . $data['language_file']);
    }
    $res = '<title>' . $GLOBALS["strConfirmTitle"] . '</title>';
    $res .= $data["header"];
    $res .= '<h1>' . $info . '</h1>';
    $res .= $html;
    $res .= "<P>" . $GLOBALS["PoweredBy"] . '</p>';
    $res .= $data["footer"];
    return $res;
}
开发者ID:alancohen,项目名称:alancohenexperience-com,代码行数:57,代码来源:index.php

示例14: isBlackListedID

function isBlackListedID($userid = 0)
{
    if (!$userid) {
        return 0;
    }
    $email = Sql_Fetch_Row_Query("select email from {$GLOBALS["tables"]["user"]} where id = {$userid}");
    return isBlackListed($email[0]);
}
开发者ID:narareddy,项目名称:phplist3,代码行数:8,代码来源:userlib.php

示例15: values

         values("%s",now(),1,1,"%s")', $tables["user"], $line, $uniqid);
     $result = Sql_query($query, 1);
     $userid = Sql_insert_id();
     if (empty($userid)) {
         $count['duplicate']++;
         ## mark the subscriber confirmed, don't touch blacklisted
         ## hmm, maybe not, can be done on the reconcile page
         #   Sql_Query(sprintf('update %s set confirmed = 1 where email = "%s"', $tables["user"], $line));
         $idreq = Sql_Fetch_Row_Query(sprintf('select id from %s where email = "%s"', $tables["user"], $line));
         $userid = $idreq[0];
     } else {
         $count['imported']++;
         addUserHistory($line, $GLOBALS['I18N']->get('import_by') . ' ' . adminName(), '');
     }
     ## do not add them to the list(s) when blacklisted
     $isBlackListed = isBlackListed($line);
     if (!$isBlackListed) {
         $count['addedtolist']++;
         foreach ($selected_lists as $k => $listid) {
             $query = "replace into " . $tables["listuser"] . " (userid,listid,entered) values({$userid},{$listid},now())";
             $result = Sql_query($query);
         }
     } else {
         $count['foundonblacklist']++;
     }
 } else {
     $count['invalid']++;
     $rejectReport['invalid'] .= "\n" . $line;
     ## @TODO hmm, this can blow up
 }
 $count['processed']++;
开发者ID:Gerberus,项目名称:phplist3,代码行数:31,代码来源:importsimple.php


注:本文中的isBlackListed函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。