php - SilverStripe 'None of these templates can be found in theme 'default' -
i have widget has 2 templates. eligibilitywidget.ss , eligibilitywidget_shortform.ss .
i running code
public function init() { $cookie = (cookie::get('__utmz')); if (isset($cookie)) { return $this->renderwith('eligibilitywidget_shortform'); } else { return $this->renderwith('eligibilitywidget'); } } this should identify if cookie exists , render information correct template. however, when run error message:
[user warning] none of these templates can found in theme 'default': widget.ss, dataobject.ss, viewabledata.ss, object.ss
i have tried changing line of code
return $this->renderwith(array('eligibilitywidget_shortform', 'widget')); however returned same error. appreciated, thank you.
Comments
Post a Comment