fuel/fuel/core/classes/theme.php
public function set_partial($section, $view, $overwrite = false)
	{
		// make sure the partial entry exists
		array_key_exists($section, $this->partials) or $this->partials[$section] = array();

		// make sure the partial is a view
		if (is_string($view))
		{
			$name = $view;
			$view = $this->view($view);
		}
		else
		{
			$name = 'partial_'.count($this->partials[$section]);
		}

		// store the partial
		if ($overwrite)
		{
			$this->partials[$section] = array($name => $view);
		}
		else
		{
			$this->partials[$section][$name] = $view;
		}

		// return the partial view object for chaining
		return $this->partials[$section][$name];
	}
public function set_partial($section, $view, $overwrite = false)
	{
		// make sure the partial entry exists
		array_key_exists($section, $this->partials) or $this->partials[$section] = array();

		// make sure the partial is a view
		if (is_string($view))
		{
			$name = $view;
			$view = $this->view($view);
		}
		else
		{
			$name = 'partial_'.count($this->partials[$section]);
		}

		// store the partial
		if ($overwrite)
		{
			$this->partials[$section] = array($name => $view);
		}
		else
		{
			$this->partials[$section][$name] = $view;
		}

		// return the partial view object for chaining
		return $this->partials[$section][$name];
	}
public function set_partial ( $ section , $ view , $ overwrite = false ) { // make sure the partial entry exists array_key_exists ( $ section , $ this -> partials ) or $ this -> partials [ $ section ] = array ( ) ; // make sure the partial is a view if ( is_string ( $ view ) ) { $ name = $ view ; $ view = $ this -> view ( $ view ) ; } else { $ name = 'partial_' . count ( $ this -> partials [ $ section ] ) ; } // store the partial if ( $ overwrite ) { $ this -> partials [ $ section ] = array ( $ name => $ view ) ; } else { $ this -> partials [ $ section ] [ $ name ] = $ view ; } // return the partial view object for chaining return $ this -> partials [ $ section ] [ $ name ] ; }
Sets a partial for the current template

@param   string  						$section   Name of the partial section in the template
@param   string|View|ViewModel|Presenter	$view      View, or name of the view
@param   bool							$overwrite If true overwrite any already defined partials for this section
@return  View
Sets a partial for the current template