示例#1
0
 function loadAllWidgets($widgetList, $params = array())
 {
     if (!is_array($widgetList)) {
         $widgetList = explode(",", $widgetList);
     } elseif (strlen($widgetList) <= 0) {
         return;
     }
     foreach ($widgetList as $a) {
         loadWidget($a, $params);
     }
 }
示例#2
0
文件: index.php 项目: druto/druto
This is Blog Index View
<form>
	<input	type="text">
</form>
<?php 
echo $title;
echo $alam;
loadWidget('Widgets.Hello', array('imageDir' => '/images'));
示例#3
0
文件: index.php 项目: druto/druto
?>
/css/bootstrap.min.css"
	rel="stylesheet">
<!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
<!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
<!--[if lt IE 9]>
      <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
      <script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script>
    <![endif]-->
</HEAd>
</head>
</head>
<body>
	<div id="sidebar">
		<?php 
loadWidget('Widgets.Hello');
?>
	</div>
	<?php 
echo $this->content;
?>

	<!-- jQuery (necessary for Bootstrap's JavaScript plugins) -->
	<script
		src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
	<!-- Include all compiled plugins (below), or include individual files as needed -->
	<script src="<?php 
echo $this->templateBaseURL;
?>
/js/bootstrap.min.js"></script>
</body>
示例#4
0
<style>
#wrapper {
	padding-left: 0px;
}
#wrapper #footer {
	left:0px;
}
</style>
<div class="container-fluid">
	<div class='articleContent'>
		<?php 
//loadModule("test");exit();
$page = explode("/", $_REQUEST['page']);
if (isset($page[count($page) - 1]) && strlen($page[count($page) - 1]) <= 0) {
    unset($page[count($page) - 1]);
}
if (count($page) <= 1) {
    $page[1] = "about";
}
loadModule("content");
$title = printContent($page[1]);
if ($title == null) {
    include APPROOT . APPS_PAGES_FOLDER . "error.php";
} else {
    if ($page[1] == "about") {
        loadWidget("socialbar");
    }
}
?>
	</div>
</div>
示例#5
0
/**
 * Smarty plugin
 *
 * @package    Smarty
 * @subpackage PluginsFunction
 * @author		Bismay Kumar Mohaptra
 */
function smarty_function_widget($params, Smarty_Internal_Template $template)
{
    $GLOBALS['PAGETMPL'] = $template->smarty;
    return loadWidget($params['src']);
}
示例#6
0
/**
 * Smarty plugin
 *
 * @package    Smarty
 * @subpackage PluginsFunction
 * @author		Bismay Kumar Mohaptra
 */
function smarty_function_widget($params)
{
    return loadWidget($params['src']);
}