本文整理汇总了PHP中sfWebRequest::isSmartphone方法的典型用法代码示例。如果您正苦于以下问题:PHP sfWebRequest::isSmartphone方法的具体用法?PHP sfWebRequest::isSmartphone怎么用?PHP sfWebRequest::isSmartphone使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类sfWebRequest
的用法示例。
在下文中一共展示了sfWebRequest::isSmartphone方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: executeMemberList
public function executeMemberList(sfWebRequest $request)
{
$this->forwardIf($request->isSmartphone(), 'like', 'smtMemberList');
$this->forward('default', 'error');
}
示例2: executeEdit
public function executeEdit(sfWebRequest $request)
{
$this->forward404Unless($this->isDiaryAuthor());
$this->forwardIf($request->isSmartphone(), 'diary', 'smtEdit');
$this->form = new DiaryForm($this->diary);
}
示例3: executeReply
/**
* Executes replyMessage action
*
* @param sfWebRequest $request A request object
*/
public function executeReply(sfWebRequest $request)
{
$this->forwardIf($request->isSmartphone(), 'message', 'smtList');
$message = Doctrine::getTable('SendMessageData')->find($request->getParameter('id'));
$this->forward404unless($message && $message->getIsReceiver($this->getUser()->getMemberId()));
$this->message = new SendMessageData();
$this->message->setMessageTypeId($message->getMessageTypeId());
$this->message->setReturnMessageId($message->getId());
if ($message->getThreadMessageId() != 0) {
$this->message->setThreadMessageId($message->getThreadMessageId());
} else {
$this->message->setThreadMessageId($message->getId());
}
$sendMemberId = $message->getMemberId();
$this->form = new SendMessageForm($this->message, array('send_member_id' => $sendMemberId));
$this->sendMember = Doctrine::getTable('Member')->find($sendMemberId);
$this->forward404Unless($this->sendMember);
$this->setTemplate('sendToFriend');
return sfView::INPUT;
}