render() public method

Method to render the child and its child nodes.
public render ( boolean $ret = false, integer $depth, string $indent = null, string $errorIndent = null ) : string
$ret boolean
$depth integer
$indent string
$errorIndent string
return string
示例#1
0
 public function testRender()
 {
     $e = new Element('text', 'email');
     $element = $e->render(true);
     $e->setErrorPre(true);
     $element = $e->render(true);
     ob_start();
     $e->output();
     $output = ob_get_clean();
     $this->assertContains('<input', $element);
     $this->assertContains('<input', $output);
 }