www.gusucode.com > 74cms PHP骑士人才系统 v3.5.1源码程序 > code/upload/include/template_lite/plugins/block.capture.php

    <?php
/**
 * template_lite {capture}{/capture} block plugin
 *
 * Type:     block function
 * Name:     capture
 * Purpose:  removes content and stores it in a variable
 */
function tpl_block_capture($params, $content, &$tpl)
{
	extract($params);

	if (isset($name))
	{
		$buffer = $name;
	}
	else
	{
		$buffer = "'default'";
	}

	$tpl->_templatelite_vars['capture'][$buffer] = $content;
	if (isset($assign))
	{
		$tpl->assign($assign, $content);
	}
	return;
}
?>