public function generateContents($code)
  {
    $content = '$' . $code->getTempVariable();

    $code->writePhp('ob_start();');

    parent :: generateContents($code);

    $code->writePhp("{$content} = ob_get_contents();ob_end_clean();");

    $code->writePhp($this->getComponentRefCode() . "->appendRequestAttributes({$content});");

    $code->writePhp("echo {$content};");
  }
  function generateContents(&$code)
  {
    $content = $code->getTempVarRef();
    $attributes = $code->getTempVarRef();

    $code->writePhp('ob_start();');

    parent :: generateContents($code);

    $code->writePhp("{$attributes} = explode(',', '" . $this->getAttribute('attributes') . "');");
    $code->writePhp("{$content} = ob_get_contents();ob_end_clean();");

    $code->writePhp($this->getComponentRefCode() . "->setAttributesToTransfer({$attributes});");
    $code->writePhp($this->getComponentRefCode() . "->appendRequestAttributes({$content});");

    $code->writePhp("echo {$content};");
  }
Example #3
0
  public function generateContents($code)
  {
    parent :: generateContents($code);

    $v = '$' . $code->getTempVariable();

    $code->writePhp("if({$v} = Limb :: toolkit()->getRequest()->get('node_id')){");
    $code->writePhp("echo \"<input type='hidden' name='node_id' value='{$v}'>\";}");
  }