本文整理汇总了PHP中uri::full_path方法的典型用法代码示例。如果您正苦于以下问题:PHP uri::full_path方法的具体用法?PHP uri::full_path怎么用?PHP uri::full_path使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类uri
的用法示例。
在下文中一共展示了uri::full_path方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: recover
function recover()
{
$this->view->content = new View('tools/recover');
if ($_POST) {
if (empty($_POST['email'])) {
return $this->view->flash = 'Your e-mail is required!';
}
$lists = new Alist_Collection();
$sql = 'SELECT * FROM alist WHERE email LIKE "' . $lists->getDb()->escape($_POST['email']) . '" ORDER BY name DESC';
$lists->loadBySql($sql);
if ($lists->isEmpty()) {
return $this->view->flash = 'No lists found for ' . $_POST['email'];
}
$body = <<<EOF
== List Recovery From MkLst.com ==
Someone (hopefully you) requested a list of all your MkLst.com lists be sent to
this address. If this was you, well, here you go. If it wasn't, sorry! Please
ignore this message or contact us at http://mklst.com/
== Your Lists ==
EOF;
foreach ($lists as $list) {
$body .= $list->getName() . "\r\n - " . uri::full_path('list/view/' . $list->getId()) . "\r\n\r\n";
}
$message = Swift_Message::newInstance();
$message->setSubject('MkLst.com List Recovery');
$message->setFrom(array('no-reply@mklst.com' => 'No Reply'));
$message->setTo(array($_POST['email']));
$message->setBody($body);
Swift_Mailer::newInstance(Swift_MailTransport::newInstance())->send($message);
$this->view->flash = 'Recovery list sent!';
}
}