widget.toString() ?

Is there a way to instantiate a widget and then get back the html as a string?

$widget = new CWidget();

$stringzz = $widget->toString();

Are you trying to get the widget's rendering result?

You may use output buffering (ob) to capture that.

Or you can use the following:




// now the result can be accessed via $this->clips['widget']

excellent, thanks qianq