本文整理汇总了PHP中BaseController::httpContent方法的典型用法代码示例。如果您正苦于以下问题:PHP BaseController::httpContent方法的具体用法?PHP BaseController::httpContent怎么用?PHP BaseController::httpContent使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类BaseController
的用法示例。
在下文中一共展示了BaseController::httpContent方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: show
/**
* Display the specified resource.
*
* @param int $id
* @return Response
*/
public function show($id)
{
if ($this->group_check->show($id)) {
return BaseController::httpNotFound();
} else {
return BaseController::httpContent($this->group_gestion->show($id), 'group');
}
}
示例2: dislikes
public function dislikes($id)
{
if ($this->vote_check->missingPost($id)) {
return BaseController::httpNotFound();
} else {
return BaseController::httpContent($this->vote_gestion->dislikes($id), 'dislikes');
}
}
示例3: waiting
public function waiting($id)
{
if ($this->list_validation->fails()) {
return BaseController::httpError($this->list_validation);
} elseif ($this->friend_check->noWaiting($id)) {
return BaseController::httpNotFound();
} else {
return BaseController::httpContent($this->friend_gestion->waiting($id), 'waiting_friends');
}
}
示例4: followers
public function followers($id)
{
if ($this->list_validation->fails()) {
return BaseController::httpError($this->list_validation);
}
if ($this->follow_check->noFollowers($id)) {
return BaseController::httpNotfound();
} else {
return BaseController::httpContent($this->follow_gestion->followers($id), 'followers');
}
}
示例5: show
/**
* Display the specified resource.
*
* @param int $id
* @return Response
*/
public function show($id)
{
if ($this->comment_check->missing($id)) {
return BaseController::httpNotFound();
} else {
return BaseController::httpContent($this->comment_gestion->show($id), 'comment');
}
}
示例6: voteFeed
public function voteFeed()
{
if ($this->list_validation->fails()) {
return BaseController::httpError($this->list_validation);
} else {
return BaseController::httpContent($this->post_gestion->voteFeed(), 'vote_feed');
}
}
示例7: login
/**
* Check if the user exist and has the right password.
*
* @return Response
*/
public function login()
{
if ($this->login_validation->fails()) {
return BaseController::httpError($this->login_validation);
} else {
if ($this->user_check->badLogin()) {
return BaseController::httpNotFound();
} else {
return BaseController::httpContent($this->user_gestion->login());
}
}
}