コード例 #1
0
ファイル: TidyResponse.php プロジェクト: mike227/n-tidy
 public function send(Nette\Http\IRequest $httpRequest, Nette\Http\IResponse $httpResponse)
 {
     ob_start();
     $this->response->send($httpRequest, $httpResponse);
     $html = ob_get_contents();
     ob_end_clean();
     echo $this->tidy->process($html);
 }
コード例 #2
0
ファイル: TextApiResponse.php プロジェクト: tomaj/nette-api
 /**
  * Create TextApiResponse
  * This class only wrap JsonResponse from Nette and add possibility
  * to setup response code and automaticaly set content type
  *
  * @param integer $code
  * @param mixed $data
  */
 public function __construct($code, $data)
 {
     parent::__construct($data);
     $this->code = $code;
 }