throw new NotFoundHttpException('The requested page does not exist.'); } } protected function findModelDoc($id) { if (($model = Documents::findOne($id)) !== null) { return $model; } else { throw new NotFoundHttpException('The requested page does not exist.'); } } }
$_GET = [ 'id' => '815', ];