本文整理汇总了PHP中sfRequest::isSmartphone方法的典型用法代码示例。如果您正苦于以下问题:PHP sfRequest::isSmartphone方法的具体用法?PHP sfRequest::isSmartphone怎么用?PHP sfRequest::isSmartphone使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类sfRequest
的用法示例。
在下文中一共展示了sfRequest::isSmartphone方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: execute
/**
* Executes this action
*
* @param sfRequest $request A request object
*/
public function execute($request)
{
if ($request->isSmartphone()) {
$this->setLayout('smtLayoutSns');
$this->setTemplate('smtUserAgreement');
}
}
示例2: executeMemberList
/**
* Executes memberList action
*
* @param sfRequest $request A request object
*/
public function executeMemberList($request)
{
$this->forward404Unless($this->acl->isAllowed($this->getUser()->getMemberId(), null, 'view'));
$this->forwardIf($request->isSmartphone(), 'communityEvent', 'smtMemberList');
if (!$this->size) {
$this->size = 20;
}
$this->pager = Doctrine::getTable('CommunityEvent')->getEventMemberListPager($this->communityEvent->getId(), $request->getParameter('page', 1), $this->size);
if (!$this->pager->getNbResults()) {
return sfView::ERROR;
}
}
示例3: executeEdit
/**
* Executes edit action
*
* @param sfRequest $request A request object
*/
public function executeEdit($request)
{
$this->forwardIf($request->isSmartphone(), 'communityTopic', 'smtEdit');
$this->form = new CommunityTopicForm($this->communityTopic);
return sfView::SUCCESS;
}