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


PHP acymailing_generateKey函数代码示例

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


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

示例1: copy

 function copy()
 {
     if (!$this->isAllowed($this->aclCat, 'manage')) {
         return;
     }
     JRequest::checkToken() || JRequest::checkToken('get') || JSession::checkToken('get') || die('Invalid Token');
     $cids = JRequest::getVar('cid', array(), '', 'array');
     $db = JFactory::getDBO();
     $time = time();
     $my = JFactory::getUser();
     $creatorId = intval($my->id);
     $addSendDate = '';
     if (!empty($this->copySendDate)) {
         $addSendDate = ', `senddate`';
     }
     foreach ($cids as $oneMailid) {
         $query = 'INSERT INTO `#__acymailing_mail` (`subject`, `body`, `altbody`, `published`' . $addSendDate . ', `created`, `fromname`, `fromemail`, `replyname`, `replyemail`, `type`, `visible`, `userid`, `alias`, `attach`, `html`, `tempid`, `key`, `frequency`, `params`,`filter`,`metakey`,`metadesc`)';
         $query .= " SELECT CONCAT('copy_',`subject`), `body`, `altbody`, 0" . $addSendDate . ", '.{$time}.', `fromname`, `fromemail`, `replyname`, `replyemail`, `type`, `visible`, '.{$creatorId}.', `alias`, `attach`, `html`, `tempid`, " . $db->Quote(acymailing_generateKey(8)) . ', `frequency`, `params`,`filter`,`metakey`,`metadesc` FROM `#__acymailing_mail` WHERE `mailid` = ' . (int) $oneMailid;
         $db->setQuery($query);
         $db->query();
         $newMailid = $db->insertid();
         $db->setQuery('INSERT IGNORE INTO `#__acymailing_listmail` (`listid`,`mailid`) SELECT `listid`,' . $newMailid . ' FROM `#__acymailing_listmail` WHERE `mailid` = ' . (int) $oneMailid);
         $db->query();
     }
     return $this->listing();
 }
开发者ID:proyectoseb,项目名称:University,代码行数:26,代码来源:newsletter.php

示例2: save

 function save($mail)
 {
     if (isset($mail->alias) or empty($mail->mailid)) {
         if (empty($mail->alias)) {
             $mail->alias = $mail->subject;
         }
         $mail->alias = JFilterOutput::stringURLSafe(trim($mail->alias));
     }
     if (empty($mail->mailid)) {
         if (empty($mail->created)) {
             $mail->created = time();
         }
         if (empty($mail->userid)) {
             $user = JFactory::getUser();
             $mail->userid = $user->id;
         }
         if (empty($mail->key)) {
             $mail->key = acymailing_generateKey(8);
         }
     } else {
         if (!empty($mail->attach)) {
             $oldMailObject = $this->get($mail->mailid);
             if (!empty($oldMailObject)) {
                 $mail->attach = array_merge($oldMailObject->attach, $mail->attach);
             }
         }
     }
     if (!empty($mail->attach) and !is_string($mail->attach)) {
         $mail->attach = serialize($mail->attach);
     }
     if (isset($mail->filter) and !is_string($mail->filter)) {
         $mail->filter = serialize($mail->filter);
     }
     if (!empty($mail->params)) {
         if (!empty($mail->params['lastgenerateddate']) && !is_numeric($mail->params['lastgenerateddate'])) {
             $mail->params['lastgenerateddate'] = acymailing_getTime($mail->params['lastgenerateddate']);
         }
         $mail->params = serialize($mail->params);
     }
     if (!empty($mail->senddate) && !is_numeric($mail->senddate)) {
         $mail->senddate = acymailing_getTime($mail->senddate);
     }
     JPluginHelper::importPlugin('acymailing');
     $dispatcher = JDispatcher::getInstance();
     if (empty($mail->mailid)) {
         $dispatcher->trigger('onAcyBeforeMailCreate', array(&$mail));
         $status = $this->database->insertObject(acymailing_table('mail'), $mail);
     } else {
         $dispatcher->trigger('onAcyBeforeMailModify', array(&$mail));
         $status = $this->database->updateObject(acymailing_table('mail'), $mail, 'mailid');
     }
     if (!$status) {
         $this->errors[] = substr(strip_tags($this->database->getErrorMsg()), 0, 200) . '...';
     }
     if (!empty($mail->params) and is_string($mail->params)) {
         $mail->params = unserialize($mail->params);
     }
     if (!empty($mail->attach) and is_string($mail->attach)) {
         $mail->attach = unserialize($mail->attach);
     }
     if ($status) {
         return empty($mail->mailid) ? $this->database->insertid() : $mail->mailid;
     }
     return false;
 }
开发者ID:proyectoseb,项目名称:ShoppyStore,代码行数:65,代码来源:mail.php

示例3: save

 function save($subscriber)
 {
     $app = JFactory::getApplication();
     $config = acymailing_config();
     JPluginHelper::importPlugin('acymailing');
     $dispatcher = JDispatcher::getInstance();
     if (isset($subscriber->email)) {
         $subscriber->email = strtolower($subscriber->email);
         $userHelper = acymailing_get('helper.user');
         if (!$userHelper->validEmail($subscriber->email, $this->extendedEmailVerif)) {
             echo "<script>alert('" . JText::_('VALID_EMAIL', true) . "'); window.history.go(-1);</script>";
             exit;
         }
     }
     if (empty($subscriber->subid)) {
         $my = JFactory::getUser();
         if ($this->checkVisitor && !$app->isAdmin() && (int) $config->get('allow_visitor', 1) != 1 && (empty($my->id) or strtolower($my->email) != $subscriber->email)) {
             echo "<script> alert('" . JText::_('ONLY_LOGGED', true) . "'); window.history.go(-1);</script>\n";
             exit;
         }
         if (empty($subscriber->email)) {
             return false;
         }
         $subscriber->subid = $this->subid($subscriber->email);
     }
     if (empty($subscriber->subid)) {
         if (empty($subscriber->created)) {
             $subscriber->created = time();
         }
         if (empty($subscriber->ip)) {
             $ipClass = acymailing_get('helper.user');
             $subscriber->ip = $ipClass->getIP();
         }
         $source = JRequest::getCmd('acy_source');
         if (empty($subscriber->source) && !empty($source)) {
             $subscriber->source = $source;
         }
         if (empty($subscriber->name) && $config->get('generate_name', 1)) {
             $subscriber->name = ucwords(trim(str_replace(array('.', '_', ')', ',', '(', '-', 1, 2, 3, 4, 5, 6, 7, 8, 9, 0), ' ', substr($subscriber->email, 0, strpos($subscriber->email, '@')))));
         }
         $subscriber->key = acymailing_generateKey(14);
         $dispatcher->trigger('onAcyBeforeUserCreate', array(&$subscriber));
         $status = $this->database->insertObject(acymailing_table('subscriber'), $subscriber);
     } else {
         if (count((array) $subscriber) > 1) {
             $dispatcher->trigger('onAcyBeforeUserModify', array(&$subscriber));
             $status = $this->database->updateObject(acymailing_table('subscriber'), $subscriber, 'subid');
         } else {
             $status = true;
         }
     }
     if (!$status) {
         return false;
     }
     $subid = empty($subscriber->subid) ? $this->database->insertid() : $subscriber->subid;
     if ($this->triggerFilterBE || !$app->isAdmin()) {
         $filterClass = acymailing_get('class.filter');
         $filterClass->subid = $subid;
         $filterClass->trigger(empty($subscriber->subid) ? 'subcreate' : 'subchange');
     }
     $classGeoloc = acymailing_get('class.geolocation');
     if (empty($subscriber->subid)) {
         $subscriber->subid = $subid;
         if ($this->geolocRight) {
             $this->geolocData = $classGeoloc->saveGeolocation('creation', $subscriber->subid);
         }
         $this->userForNotification = $subscriber;
         $resultsTrigger = $dispatcher->trigger('onAcyUserCreate', array($subscriber));
         $this->recordHistory = true;
         $action = 'created';
     } else {
         if ($this->geolocRight) {
             $this->geolocData = $classGeoloc->saveGeolocation('modify', $subscriber->subid);
         }
         $resultsTrigger = $dispatcher->trigger('onAcyUserModify', array($subscriber));
         $action = 'modified';
     }
     if ($this->recordHistory) {
         $historyClass = acymailing_get('class.acyhistory');
         $historyClass->insert($subscriber->subid, $action);
         $this->recordHistory = false;
     }
     if ($this->forceConf || (!$app->isAdmin() and $this->sendConf)) {
         $this->sendConf($subid);
     }
     return $subid;
 }
开发者ID:sumithMadhushan,项目名称:joomla-project,代码行数:87,代码来源:subscriber.php

示例4: replaceSubscriptionTag

 function replaceSubscriptionTag(&$allresults, $i, &$user, &$email)
 {
     if (empty($user->subid)) {
         return '';
     }
     if (empty($user->key)) {
         $user->key = acymailing_generateKey(14);
         $db = JFactory::getDBO();
         $db->setQuery('UPDATE ' . acymailing_table('subscriber') . ' SET `key`= ' . $db->Quote($user->key) . ' WHERE subid = ' . (int) $user->subid . ' LIMIT 1');
         $db->query();
     }
     $config = acymailing_config();
     $itemId = $config->get('itemid', 0);
     $item = empty($itemId) ? '' : '&Itemid=' . $itemId;
     $lang = empty($email->language) ? '' : '&lang=' . $email->language;
     if ($allresults[1][$i] == 'confirm') {
         //confirm your subscription link
         $itemId = $this->params->get('confirmitemid', 0);
         if (!empty($itemId)) {
             $item = '&Itemid=' . $itemId;
         }
         $myLink = acymailing_frontendLink('index.php?subid=' . $user->subid . '&option=com_acymailing&ctrl=user&task=confirm&key=' . urlencode($user->key) . $item . $lang, (bool) $this->params->get('confirmtemplate', false));
         if (empty($allresults[2][$i])) {
             return $myLink;
         }
         return '<a target="_blank" href="' . $myLink . '">' . $allresults[2][$i] . '</a>';
     } elseif ($allresults[1][$i] == 'modify') {
         //modify your subscription link
         $itemId = $this->params->get('modifyitemid', 0);
         if (!empty($itemId)) {
             $item = '&Itemid=' . $itemId;
         }
         $myLink = acymailing_frontendLink('index.php?subid=' . $user->subid . '&option=com_acymailing&ctrl=user&task=modify&key=' . urlencode($user->key) . $item . $lang, (bool) $this->params->get('modifytemplate', false));
         if (empty($allresults[2][$i])) {
             return $myLink;
         }
         return '<a style="text-decoration:none;" target="_blank" href="' . $myLink . '"><span class="acymailing_unsub">' . $allresults[2][$i] . '</span></a>';
     }
     //unsubscribe link
     $itemId = $this->params->get('unsubscribeitemid', 0);
     if (!empty($itemId)) {
         $item = '&Itemid=' . $itemId;
     }
     $myLink = acymailing_frontendLink('index.php?subid=' . $user->subid . '&option=com_acymailing&ctrl=user&task=out&mailid=' . $email->mailid . '&key=' . urlencode($user->key) . $item . $lang, (bool) $this->params->get('unsubscribetemplate', false));
     if (!$this->listunsubscribe && $this->params->get('listunsubscribe', 0) && method_exists($email, 'addCustomHeader')) {
         $this->listunsubscribe = true;
         $mailto = $this->params->get('listunsubscribeemail');
         if (empty($mailto)) {
             $mailto = @$email->replyemail;
         }
         if (empty($mailto)) {
             $mailto = $config->get('reply_email');
         }
         $email->addCustomHeader('List-Unsubscribe: <' . $myLink . '>, <mailto:' . $mailto . '?subject=unsubscribe_user_' . $user->subid . '&body=Please%20unsubscribe%20user%20ID%20' . $user->subid . '>');
     }
     if (empty($allresults[2][$i])) {
         return $myLink;
     }
     return '<a style="text-decoration:none;" target="_blank" href="' . $myLink . '"><span class="acymailing_unsub">' . $allresults[2][$i] . '</span></a>';
 }
开发者ID:ForAEdesWeb,项目名称:AEW1,代码行数:60,代码来源:tagsubscription.php

示例5: sendOne


//.........这里部分代码省略.........
         $this->Body = $this->defaultMail[$mailid]->body;
         if ($this->config->get('multiple_part', false)) {
             $this->AltBody = $this->defaultMail[$mailid]->altbody;
         }
     } else {
         $this->Body = $this->defaultMail[$mailid]->altbody;
     }
     $this->setFrom($this->defaultMail[$mailid]->fromemail, $this->defaultMail[$mailid]->fromname);
     $this->_addReplyTo($this->defaultMail[$mailid]->replyemail, $this->defaultMail[$mailid]->replyname);
     if (!empty($this->defaultMail[$mailid]->attachments)) {
         if ($this->config->get('embed_files')) {
             foreach ($this->defaultMail[$mailid]->attachments as $attachment) {
                 $this->AddAttachment($attachment->filename);
             }
         } else {
             $attachStringHTML = '<br /><fieldset><legend>' . JText::_('ATTACHMENTS') . '</legend><table>';
             $attachStringText = "\n" . "\n" . '------- ' . JText::_('ATTACHMENTS') . ' -------';
             foreach ($this->defaultMail[$mailid]->attachments as $attachment) {
                 $attachStringHTML .= '<tr><td><a href="' . $attachment->url . '" target="_blank">' . $attachment->name . '</a></td></tr>';
                 $attachStringText .= "\n" . '-- ' . $attachment->name . ' ( ' . $attachment->url . ' )';
             }
             $attachStringHTML .= '</table></fieldset>';
             if ($this->sendHTML) {
                 $this->Body .= $attachStringHTML;
                 if (!empty($this->AltBody)) {
                     $this->AltBody .= "\n" . $attachStringText;
                 }
             } else {
                 $this->Body .= $attachStringText;
             }
         }
     }
     if (!empty($this->parameters)) {
         $this->generateAllParams();
         $keysparams = array_keys($this->parameters);
         $this->Subject = str_replace($keysparams, $this->parameters, $this->Subject);
         $this->Body = str_replace($keysparams, $this->parameters, $this->Body);
         if (!empty($this->AltBody)) {
             $this->AltBody = str_replace($keysparams, $this->parameters, $this->AltBody);
         }
         if (!empty($this->From)) {
             str_replace($keysparams, $this->parameters, $this->From);
         }
         if (!empty($this->FromName)) {
             str_replace($keysparams, $this->parameters, $this->FromName);
         }
         if (!empty($this->ReplyTo)) {
             foreach ($this->ReplyTo as $i => $replyto) {
                 foreach ($replyto as $a => $oneval) {
                     $this->ReplyTo[$i][$a] = str_replace($keysparams, $this->parameters, $this->ReplyTo[$i][$a]);
                 }
             }
         }
     }
     if (!empty($this->introtext)) {
         $this->Body = $this->introtext . $this->Body;
         $this->AltBody = $this->textVersion($this->introtext) . $this->AltBody;
     }
     $this->body =& $this->Body;
     $this->altbody =& $this->AltBody;
     $this->subject =& $this->Subject;
     $this->from =& $this->From;
     $this->fromName =& $this->FromName;
     $this->replyto =& $this->ReplyTo;
     $this->replyname = $this->defaultMail[$mailid]->replyname;
     $this->replyemail = $this->defaultMail[$mailid]->replyemail;
     $this->mailid = $this->defaultMail[$mailid]->mailid;
     $this->key = $this->defaultMail[$mailid]->key;
     $this->alias = $this->defaultMail[$mailid]->alias;
     $this->type = $this->defaultMail[$mailid]->type;
     $this->tempid = $this->defaultMail[$mailid]->tempid;
     $this->sentby = $this->defaultMail[$mailid]->sentby;
     $this->userid = $this->defaultMail[$mailid]->userid;
     $this->filter = $this->defaultMail[$mailid]->filter;
     $this->template = @$this->defaultMail[$mailid]->template;
     $this->language = @$this->defaultMail[$mailid]->language;
     if (empty($receiver->key) && !empty($receiver->subid)) {
         $receiver->key = acymailing_generateKey(14);
         $db = JFactory::getDBO();
         $db->setQuery('UPDATE ' . acymailing_table('subscriber') . ' SET `key`= ' . $db->Quote($receiver->key) . ' WHERE subid = ' . (int) $receiver->subid . ' LIMIT 1');
         $db->query();
     }
     $this->dispatcher->trigger('acymailing_replaceusertags', array(&$this, &$receiver, true));
     if ($this->sendHTML) {
         if (!empty($this->AltBody)) {
             $this->AltBody = $this->textVersion($this->AltBody, false);
         }
     } else {
         $this->Body = $this->textVersion($this->Body, false);
     }
     $status = $this->send();
     if ($this->trackEmail) {
         $helperQueue = acymailing_get('helper.queue');
         $statsAdd = array();
         $statsAdd[$this->mailid][$status][$this->sendHTML][] = $receiver->subid;
         $helperQueue->statsAdd($statsAdd);
         $this->trackEmail = false;
     }
     return $status;
 }
开发者ID:DanyCan,项目名称:wisten.github.io,代码行数:101,代码来源:acymailer.php

示例6: addPref

 function addPref()
 {
     $conf = JFactory::getConfig();
     $this->level = ucfirst($this->level);
     $allPref = array();
     $allPref['level'] = $this->level;
     $allPref['version'] = $this->version;
     $allPref['smtp_port'] = '';
     if (ACYMAILING_J30) {
         $allPref['from_name'] = $conf->get('fromname');
         $allPref['from_email'] = $conf->get('mailfrom');
         $allPref['bounce_email'] = $conf->get('mailfrom');
         $allPref['mailer_method'] = $conf->get('mailer');
         $allPref['sendmail_path'] = $conf->get('sendmail');
         $smtpinfos = explode(':', $conf->get('smtphost'));
         $allPref['smtp_port'] = $conf->get('smtpport');
         $allPref['smtp_secured'] = $conf->get('smtpsecure');
         $allPref['smtp_auth'] = $conf->get('smtpauth');
         $allPref['smtp_username'] = $conf->get('smtpuser');
         $allPref['smtp_password'] = $conf->get('smtppass');
     } else {
         $allPref['from_name'] = $conf->getValue('config.fromname');
         $allPref['from_email'] = $conf->getValue('config.mailfrom');
         $allPref['bounce_email'] = $conf->getValue('config.mailfrom');
         $allPref['mailer_method'] = $conf->getValue('config.mailer');
         $allPref['sendmail_path'] = $conf->getValue('config.sendmail');
         $smtpinfos = explode(':', $conf->getValue('config.smtphost'));
         $allPref['smtp_secured'] = $conf->getValue('config.smtpsecure');
         $allPref['smtp_auth'] = $conf->getValue('config.smtpauth');
         $allPref['smtp_username'] = $conf->getValue('config.smtpuser');
         $allPref['smtp_password'] = $conf->getValue('config.smtppass');
     }
     $allPref['reply_name'] = $allPref['from_name'];
     $allPref['reply_email'] = $allPref['from_email'];
     $allPref['cron_sendto'] = $allPref['from_email'];
     $allPref['add_names'] = '1';
     $allPref['encoding_format'] = '8bit';
     $allPref['charset'] = 'UTF-8';
     $allPref['word_wrapping'] = '150';
     $allPref['hostname'] = '';
     $allPref['embed_images'] = '0';
     $allPref['embed_files'] = '1';
     $allPref['editor'] = 'acyeditor';
     $allPref['multiple_part'] = '1';
     $allPref['smtp_host'] = $smtpinfos[0];
     if (isset($smtpinfos[1])) {
         $allPref['smtp_port'] = $smtpinfos[1];
     }
     if (!in_array($allPref['smtp_secured'], array('tls', 'ssl'))) {
         $allPref['smtp_secured'] = '';
     }
     $allPref['queue_nbmail'] = '40';
     $allPref['queue_nbmail_auto'] = '70';
     $allPref['queue_type'] = 'auto';
     $allPref['queue_try'] = '3';
     $allPref['queue_pause'] = '120';
     $allPref['allow_visitor'] = '1';
     $allPref['require_confirmation'] = '0';
     $allPref['priority_newsletter'] = '3';
     $allPref['allowedfiles'] = 'zip,doc,docx,pdf,xls,txt,gzip,rar,jpg,jpeg,gif,xlsx,pps,csv,bmp,ico,odg,odp,ods,odt,png,ppt,swf,xcf,mp3,wma';
     $allPref['uploadfolder'] = 'media/com_acymailing/upload';
     $allPref['confirm_redirect'] = '';
     $allPref['subscription_message'] = '1';
     $allPref['notification_unsuball'] = '';
     $allPref['cron_next'] = '1251990901';
     $allPref['confirmation_message'] = '1';
     $allPref['welcome_message'] = '1';
     $allPref['unsub_message'] = '1';
     $allPref['cron_last'] = '0';
     $allPref['cron_fromip'] = '';
     $allPref['cron_report'] = '';
     $allPref['cron_frequency'] = '900';
     $allPref['cron_sendreport'] = '2';
     $allPref['cron_fullreport'] = '1';
     $allPref['cron_savereport'] = '2';
     $allPref['cron_savepath'] = 'media/com_acymailing/logs/report' . rand(0, 999999999) . '.log';
     $allPref['notification_created'] = '';
     $allPref['notification_accept'] = '';
     $allPref['notification_refuse'] = '';
     $allPref['forward'] = '0';
     $descriptions = array('Joomla!® Newsletter Extension', 'Joomla!® Mailing Extension', 'Joomla!® Newsletter System', 'Joomla!® E-mail Marketing', 'Joomla!® Marketing Campaign');
     $allPref['description_starter'] = $descriptions[rand(0, 4)];
     $allPref['description_essential'] = $descriptions[rand(0, 4)];
     $allPref['description_business'] = $descriptions[rand(0, 4)];
     $allPref['description_enterprise'] = $descriptions[rand(0, 4)];
     $allPref['priority_followup'] = '2';
     $allPref['unsub_redirect'] = '';
     $allPref['use_sef'] = '0';
     $allPref['itemid'] = '0';
     $allPref['css_module'] = 'default';
     $allPref['css_frontend'] = 'default';
     $allPref['css_backend'] = '';
     $allPref['bootstrap_frontend'] = 0;
     $allPref['unsub_reasons'] = serialize(array('UNSUB_SURVEY_FREQUENT', 'UNSUB_SURVEY_RELEVANT'));
     $allPref['security_key'] = acymailing_generateKey(30);
     $app = JFactory::getApplication();
     $allPref['installcomplete'] = '0';
     $allPref['Starter'] = '0';
     $allPref['Essential'] = '1';
     $allPref['Business'] = '2';
//.........这里部分代码省略.........
开发者ID:Roma48,项目名称:abazherka,代码行数:101,代码来源:install.acymailing.php

示例7: _checkData

 function _checkData(&$user)
 {
     if (empty($user->created)) {
         $user->created = time();
     } elseif (!is_numeric($user->created)) {
         $user->created = strtotime($user->created);
     }
     if (!isset($user->accept) || strlen($user->accept) == 0) {
         $user->accept = 1;
     }
     if (!isset($user->enabled) || strlen($user->enabled) == 0) {
         $user->enabled = 1;
     }
     if (!isset($user->html) || strlen($user->html) == 0) {
         $user->html = 1;
     }
     if (empty($user->source)) {
         $user->source = 'import';
     }
     if (!empty($user->confirmed_date) && !is_numeric($user->confirmed_date)) {
         $user->confirmed_date = strtotime($user->confirmed_date);
     }
     if (!empty($user->lastclick_date) && !is_numeric($user->lastclick_date)) {
         $user->lastclick_date = strtotime($user->lastclick_date);
     }
     if (!empty($user->lastopen_date) && !is_numeric($user->lastopen_date)) {
         $user->lastopen_date = strtotime($user->lastopen_date);
     }
     if (!empty($user->lastsent_date) && !is_numeric($user->lastsent_date)) {
         $user->lastsent_date = strtotime($user->lastsent_date);
     }
     if (empty($user->name) and $this->generatename) {
         $user->name = ucwords(trim(str_replace(array('.', '_', '-', 1, 2, 3, 4, 5, 6, 7, 8, 9, 0), ' ', substr($user->email, 0, strpos($user->email, '@')))));
     }
     if (!isset($user->confirmed) || strlen($user->confirmed) == 0 and $this->forceconfirm) {
         $user->confirmed = 1;
     }
     if (empty($user->key)) {
         $user->key = acymailing_generateKey(14);
     }
 }
开发者ID:sumithMadhushan,项目名称:joomla-project,代码行数:41,代码来源:import.php

示例8: acymailing_tooltip

			<tr>
				<td colspan="2">
					<table class="admintable" cellspacing="1">
						<tr>
							<td class="key">
								<?php echo acymailing_tooltip(JText::_('CAPTCHA_CHARS_DESC'), JText::_('CAPTCHA_CHARS'), '', JText::_('CAPTCHA_CHARS')); ?>
							</td>
							<td>
								<input class="inputbox" type="text" name="config[captcha_chars]" style="width:450px" value="<?php echo $this->escape($this->config->get('captcha_chars','abcdefghijkmnpqrstwxyz23456798ABCDEFGHJKLMNPRSTUVWXYZ')); ?>" />
							</td>
						</tr>
						<tr>
							<td class="key">
								<?php $secKey = $this->config->get('security_key');
								if(empty($secKey)){
									$secKey = acymailing_generateKey(30);
								}
								echo acymailing_tooltip(JText::sprintf('SECURITY_KEY_DESC','index.php?option=com_acymailing&ctrl=sub&task=optin&seckey='.$secKey), JText::_('SECURITY_KEY'), '', JText::_('SECURITY_KEY')); ?>
							</td>
							<td>
								<input class="inputbox" type="text" name="config[security_key]" style="width:300px" value="<?php echo $this->escape($secKey); ?>" />
							</td>
						</tr>
					</table>
				</td>
			</tr>
			<tr>
				<td width="50%">
					<fieldset class="adminform">
						<legend><?php echo JText::_('MODULE_VIEW'); ?></legend>
						<table class="admintable" cellspacing="1">
开发者ID:utopszkij,项目名称:lmp,代码行数:31,代码来源:security.php


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