Exemplo n.º 1
0
 public function executeLoad_friends(sfWebRequest $request)
 {
     $this->getResponse()->setHttpHeader('Access-Control-Allow-Origin', '*');
     $this->getResponse()->setContentType('text/html');
     $this->setLayout(false);
     $lUserId = $request->getParameter('u_id');
     $lSocialObjectId = $request->getParameter('so_id');
     $lReturn['success'] = false;
     $lReturn['html'] = false;
     $this->pFriends = array();
     if ($lUserId && $lSocialObjectId) {
         $this->pFriends = array_slice(UserTable::getFriendIdsBySocialObjectId($lSocialObjectId, $lUserId), 0, 3);
     }
     return $lReturn['html'];
 }