ZF-4222: Zend_Layout::render include two nonexistent method in Zend_View_Interface


// line 712 @ ZF 1.6.0
public function render($name = null) 
    // $this->getView() will return an instance of Zend_View_Interface
    $view = $this->getView();

    // *but the Zend_View_Interface has no addScriptPath() and addBasePath() method*
    if (null !== ($path = $this->getViewScriptPath())) {
    } elseif (null !== ($path = $this->getViewBasePath())) {
        $view->{color:red}addBasePath{color}($path, $this->_viewBasePrefix);

    return $view->render($name);


Actually, Zend_View_Interface does have addBasePath(), just not addScriptPath(). Additionally, Z_V_I has setScriptPath(), but no addScriptPath(). The solution is to check with method_exists() and switch based on it.

Fixed in trunk at r11375 Fixed in release 1.6 at r11376