public function indexAction() { if ($this->get('request')->isXmlHttpRequest() && $this->get('request')->getMethod() == 'POST') { $text = $this->get('request')->get('text'); $zcode = new Zcode(); $rep = new Response($zcode->zcodeify($text)); return $rep; } else { throw new NotFoundHttpException(); } }
public function zcoderender($text) { $zcode = new Zcode(); return $zcode->zcodeify($text); }