public function & Render ($typePath = '', $relativePath = '') {
		/** @var $this \MvcCore\View */
		if (!$typePath) $typePath = static::$scriptsDir;
		$result = '';
		$relativePath = $this->_correctRelativePath(
			$typePath, $relativePath
		);
		$viewScriptFullPath = static::GetViewScriptFullPath($typePath, $relativePath);
		if (!file_exists($viewScriptFullPath)) {
			$selfClass = version_compare(PHP_VERSION, '5.5', '>') ? self::class : __CLASS__;
			throw new \InvalidArgumentException('['.$selfClass."] Template not found in path: `$viewScriptFullPath`.");
		}
		$renderedFullPaths = & $this->__protected['renderedFullPaths'];
		$renderedFullPaths[] = $viewScriptFullPath;
		ob_start();
		include($viewScriptFullPath);
		$result = ob_get_clean();
		\array_pop($renderedFullPaths); // unset last
		return $result;
	}
public function & Render ($typePath = '', $relativePath = '') {
		/** @var $this \MvcCore\View */
		if (!$typePath) $typePath = static::$scriptsDir;
		$result = '';
		$relativePath = $this->_correctRelativePath(
			$typePath, $relativePath
		);
		$viewScriptFullPath = static::GetViewScriptFullPath($typePath, $relativePath);
		if (!file_exists($viewScriptFullPath)) {
			$selfClass = version_compare(PHP_VERSION, '5.5', '>') ? self::class : __CLASS__;
			throw new \InvalidArgumentException('['.$selfClass."] Template not found in path: `$viewScriptFullPath`.");
		}
		$renderedFullPaths = & $this->__protected['renderedFullPaths'];
		$renderedFullPaths[] = $viewScriptFullPath;
		ob_start();
		include($viewScriptFullPath);
		$result = ob_get_clean();
		\array_pop($renderedFullPaths); // unset last
		return $result;
	}
public function & Render ( $ typePath = '' , $ relativePath = '' ) { /** @var $this \MvcCore\View */ if ( ! $ typePath ) $ typePath = static :: $ scriptsDir ; $ result = '' ; $ relativePath = $ this -> _correctRelativePath ( $ typePath , $ relativePath ) ; $ viewScriptFullPath = static :: GetViewScriptFullPath ( $ typePath , $ relativePath ) ; if ( ! file_exists ( $ viewScriptFullPath ) ) { $ selfClass = version_compare ( PHP_VERSION , '5.5' , '>' ) ? self :: class : __CLASS__ ; throw new \ InvalidArgumentException ( '[' . $ selfClass . "] Template not found in path: `$viewScriptFullPath`." ) ; } $ renderedFullPaths = & $ this -> __protected [ 'renderedFullPaths' ] ; $ renderedFullPaths [ ] = $ viewScriptFullPath ; ob_start ( ) ; include ( $ viewScriptFullPath ) ; $ result = ob_get_clean ( ) ; \ array_pop ( $ renderedFullPaths ) ; // unset last return $ result ; }
Render controller template and all necessary layout
templates and return rendered result as string reference.
@param string $typePath By default: `"Layouts" | "Scripts"`. It could be `"Forms" | "Forms/Fields"` etc...
@param string $relativePath
@throws \InvalidArgumentException Template not found in path: `$viewScriptFullPath`.
@return string
Render controller template and all necessary layout templates and return rendered result as string reference .