libraries/MVC/BController.php
public function LoadView($viewname){
		$fn=BCOMPONENTSAPPLICATIONPATH.$this->componentname.DIRECTORY_SEPARATOR.'views'.DIRECTORY_SEPARATOR.$viewname.'.php';
		if(!file_exists($fn)){
			$fn=BCOMPONENTSFRAMEWORKPATH.$this->componentname.DIRECTORY_SEPARATOR.'views'.DIRECTORY_SEPARATOR.$viewname.'.php';
			}
		$class='View_'.$this->componentname.'_'.$viewname;
		if(!file_exists($fn)){
			return NULL;
			}
		require_once($fn);
		$view=new $class;
		$view->controller=$this;
		$view->componentname=$this->componentname;
		$view->templatename=$this->templatename;
		$view->viewname=$viewname;
		$view->init();
		return $view;
		}
public function LoadView($viewname){
		$fn=BCOMPONENTSAPPLICATIONPATH.$this->componentname.DIRECTORY_SEPARATOR.'views'.DIRECTORY_SEPARATOR.$viewname.'.php';
		if(!file_exists($fn)){
			$fn=BCOMPONENTSFRAMEWORKPATH.$this->componentname.DIRECTORY_SEPARATOR.'views'.DIRECTORY_SEPARATOR.$viewname.'.php';
			}
		$class='View_'.$this->componentname.'_'.$viewname;
		if(!file_exists($fn)){
			return NULL;
			}
		require_once($fn);
		$view=new $class;
		$view->controller=$this;
		$view->componentname=$this->componentname;
		$view->templatename=$this->templatename;
		$view->viewname=$viewname;
		$view->init();
		return $view;
		}
public function LoadView ( $ viewname ) { $ fn = BCOMPONENTSAPPLICATIONPATH . $ this -> componentname . DIRECTORY_SEPARATOR . 'views' . DIRECTORY_SEPARATOR . $ viewname . '.php' ; if ( ! file_exists ( $ fn ) ) { $ fn = BCOMPONENTSFRAMEWORKPATH . $ this -> componentname . DIRECTORY_SEPARATOR . 'views' . DIRECTORY_SEPARATOR . $ viewname . '.php' ; } $ class = 'View_' . $ this -> componentname . '_' . $ viewname ; if ( ! file_exists ( $ fn ) ) { return NULL ; } require_once ( $ fn ) ; $ view = new $ class ; $ view -> controller = $ this ; $ view -> componentname = $ this -> componentname ; $ view -> templatename = $ this -> templatename ; $ view -> viewname = $ viewname ; $ view -> init ( ) ; return $ view ; }
Load the view of current component by alias

@param string $viewname
@return null|\BView
Load the view of current component by alias