本文整理汇总了PHP中smarty_modifier_default函数的典型用法代码示例。如果您正苦于以下问题:PHP smarty_modifier_default函数的具体用法?PHP smarty_modifier_default怎么用?PHP smarty_modifier_default使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了smarty_modifier_default函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: smarty_fun_headLink
function smarty_fun_headLink(&$smarty, $params)
{
$_fun_tpl_vars = $smarty->_tpl_vars;
$smarty->assign($params);
?>
<?php
if ($smarty->_tpl_vars['title']) {
?>
<?php
$smarty->assign('sortOrder', is_array($_tmp = array_pop(explode('_', $smarty->_tpl_vars['sortField']))) ? $smarty->_run_mod_handler('default', true, $_tmp, 'asc') : smarty_modifier_default($_tmp, 'asc'));
?>
<?php
if ($smarty->_tpl_vars['sortOrder'] != 'asc' && $smarty->_tpl_vars['sortOrder'] != 'desc') {
$smarty->assign('sortOrder', 'asc');
}
?>
<?php
if ($smarty->_tpl_vars['sortField'] == $smarty->_tpl_vars['sortVar'] . "_" . $smarty->_tpl_vars['sortOrder']) {
?>
<?php
$smarty->assign('currentOrder', $smarty->_tpl_vars['sortOrder']);
?>
<?php
if ($smarty->_tpl_vars['sortOrder'] == 'asc') {
$smarty->assign('sortOrder', 'desc');
} else {
$smarty->assign('sortOrder', 'asc');
}
?>
<?php
}
?>
<a href="<?php
echo smarty_function_link(array('self' => true, 'sort' => $smarty->_tpl_vars['sortVar'] . "_" . $smarty->_tpl_vars['sortOrder']), $smarty);
?>
" class="<?php
if ($smarty->_tpl_vars['currentOrder']) {
?>
direction_<?php
echo $smarty->_tpl_vars['currentOrder'];
}
?>
"><?php
echo smarty_function_translate(array('text' => $smarty->_tpl_vars['title']), $smarty);
?>
</a>
<?php
}
$smarty->_tpl_vars = $_fun_tpl_vars;
}
示例2: smarty_fun_attributeValue
function smarty_fun_attributeValue(&$smarty, $params)
{
$_fun_tpl_vars = $smarty->_tpl_vars;
$smarty->assign($params);
$smarty->assign('field', is_array($_tmp = @$smarty->_tpl_vars['field']) ? $smarty->_run_mod_handler('default', true, $_tmp, 'SpecField') : smarty_modifier_default($_tmp, 'SpecField'));
if ($smarty->_tpl_vars['attr']['values']) {
?>
<ul class="attributeList<?php
if (count($smarty->_tpl_vars['attr']['values']) == 1) {
?>
singleValue<?php
}
?>
"><?php
$_from = $smarty->_tpl_vars['attr']['values'];
if (!is_array($_from) && !is_object($_from)) {
settype($_from, 'array');
}
if (count($_from)) {
foreach ($_from as $smarty->_tpl_vars['value']) {
?>
<li> <?php
echo $smarty->_tpl_vars['value']['value_lang'];
?>
</li><?php
}
}
unset($_from);
?>
</ul>
<?php
} elseif ($smarty->_tpl_vars['attr']['value_lang']) {
echo $smarty->_tpl_vars['attr']['value_lang'];
?>
<?php
} elseif ($smarty->_tpl_vars['attr']['value']) {
echo $smarty->_tpl_vars['attr'][$smarty->_tpl_vars['field']]['valuePrefix_lang'];
echo $smarty->_tpl_vars['attr']['value'];
echo $smarty->_tpl_vars['attr'][$smarty->_tpl_vars['field']]['valueSuffix_lang'];
?>
<?php
}
$smarty->_tpl_vars = $_fun_tpl_vars;
}
示例3: is_array
conditions : [{'name':'name','op':'like','end':'%','value':''}],
required_list : ['<?php
echo $this->_tpl_vars['contact_def'][$this->_tpl_vars['selectFields']['Accounts']]['id_name'];
?>
'],
order : 'name',
limit : '10'
}
</script>
<?php
}
?>
</td></tr></table>
</h4>
<table width="100%" border="0" cellspacing="1" cellpadding="0" class="<?php
echo is_array($_tmp = @$this->_tpl_vars['def']['templateMeta']['panelClass']) ? $this->_run_mod_handler('default', true, $_tmp, 'edit view') : smarty_modifier_default($_tmp, 'edit view');
?>
" id ="createAccounts" <?php
if (!$this->_tpl_vars['def']['required'] || !empty($this->_tpl_vars['def']['select'])) {
?>
style="display:none"<?php
}
?>
>
<tr>
<td valign="top" id='name_label' width='12.5%' scope="row">
<?php
ob_start();
echo smarty_function_sugar_translate(array('label' => 'LBL_NAME', 'module' => 'Accounts'), $this);
?>
示例4: smarty_core_load_plugins
<?php
/* Smarty version 2.6.26, created on 2015-06-12 07:56:29
compiled from C:%5Cwamp%5Cwww%5CGift%5Chtml/../data/Smarty/templates/default_en-US/footer.tpl */
require_once SMARTY_CORE_DIR . 'core.load_plugins.php';
smarty_core_load_plugins(array('plugins' => array(array('modifier', 'script_escape', 'C:\\wamp\\www\\Gift\\html/../data/Smarty/templates/default_en-US/footer.tpl', 28, false), array('modifier', 'date_format', 'C:\\wamp\\www\\Gift\\html/../data/Smarty/templates/default_en-US/footer.tpl', 28, false), array('modifier', 'default', 'C:\\wamp\\www\\Gift\\html/../data/Smarty/templates/default_en-US/footer.tpl', 29, false), array('modifier', 'h', 'C:\\wamp\\www\\Gift\\html/../data/Smarty/templates/default_en-US/footer.tpl', 29, false))), $this);
?>
<!--▼FOOTER-->
<div id="footer_wrap">
<div id="footer" class="clearfix">
<div id="pagetop"><a href="#top">Top of page</a></div>
<div id="copyright">Copyright ©
<?php
if ((is_array($_tmp = @RELEASE_YEAR) ? $this->_run_mod_handler('script_escape', true, $_tmp) : smarty_modifier_script_escape($_tmp)) != (is_array($_tmp = is_array($_tmp = time()) ? $this->_run_mod_handler('script_escape', true, $_tmp) : smarty_modifier_script_escape($_tmp)) ? $this->_run_mod_handler('date_format', true, $_tmp, "%Y") : smarty_modifier_date_format($_tmp, "%Y"))) {
echo is_array($_tmp = @RELEASE_YEAR) ? $this->_run_mod_handler('script_escape', true, $_tmp) : smarty_modifier_script_escape($_tmp);
?>
-<?php
}
echo is_array($_tmp = is_array($_tmp = time()) ? $this->_run_mod_handler('script_escape', true, $_tmp) : smarty_modifier_script_escape($_tmp)) ? $this->_run_mod_handler('date_format', true, $_tmp, "%Y") : smarty_modifier_date_format($_tmp, "%Y");
?>
<?php
echo is_array($_tmp = is_array($_tmp = is_array($_tmp = $this->_tpl_vars['arrSiteInfo']['shop_name_eng']) ? $this->_run_mod_handler('script_escape', true, $_tmp) : smarty_modifier_script_escape($_tmp)) ? $this->_run_mod_handler('default', true, $_tmp, is_array($_tmp = $this->_tpl_vars['arrSiteInfo']['shop_name']) ? $this->_run_mod_handler('script_escape', true, $_tmp) : smarty_modifier_script_escape($_tmp)) : smarty_modifier_default($_tmp, is_array($_tmp = $this->_tpl_vars['arrSiteInfo']['shop_name']) ? $this->_run_mod_handler('script_escape', true, $_tmp) : smarty_modifier_script_escape($_tmp))) ? $this->_run_mod_handler('h', true, $_tmp) : smarty_modifier_h($_tmp);
?>
All rights reserved.
</div>
</div>
</div>
<!--▲FOOTER-->
示例5: is_array
<?php
} else {
?>
<?php
echo is_array($_tmp = smarty_function_math(array('equation' => "x-10", 'x' => $this->_tpl_vars['currentYear']), $this)) ? $this->_run_mod_handler('assign', true, $_tmp, 'minYear') : $this->_plugins['modifier']['assign'][0][0]->smartyAssign($_tmp, 'minYear');
?>
<?php
echo is_array($_tmp = smarty_function_math(array('equation' => "x+2", 'x' => $this->_tpl_vars['currentYear']), $this)) ? $this->_run_mod_handler('assign', true, $_tmp, 'maxYear') : $this->_plugins['modifier']['assign'][0][0]->smartyAssign($_tmp, 'maxYear');
?>
<?php
}
?>
<?php
echo smarty_function_html_select_date(array('prefix' => 'datePublished', 'time' => is_array($_tmp = @$this->_tpl_vars['datePublished']) ? $this->_run_mod_handler('default', true, $_tmp, "---") : smarty_modifier_default($_tmp, "---"), 'all_extra' => "class=\"selectMenu\"", 'start_year' => $this->_tpl_vars['minYear'], 'end_year' => $this->_tpl_vars['maxYear'], 'year_empty' => "-", 'month_empty' => "-", 'day_empty' => "-"), $this);
?>
<?php
} else {
?>
<?php
echo $this->_plugins['function']['translate'][0][0]->smartyTranslate(array('key' => "editor.issues.unpublished"), $this);
?>
<?php
}
?>
<?php
if ($this->_tpl_vars['issue']->getDateNotified()) {
示例6: is_array
if (is_array($_tmp = $this->_tpl_vars['tpl_login']) ? $this->_run_mod_handler('script_escape', true, $_tmp) : smarty_modifier_script_escape($_tmp)) {
?>
<p class="btn">
Welcome
<span class="user_name"><?php
echo is_array($_tmp = is_array($_tmp = $this->_tpl_vars['tpl_name1']) ? $this->_run_mod_handler('script_escape', true, $_tmp) : smarty_modifier_script_escape($_tmp)) ? $this->_run_mod_handler('h', true, $_tmp) : smarty_modifier_h($_tmp);
?>
<?php
echo is_array($_tmp = is_array($_tmp = $this->_tpl_vars['tpl_name2']) ? $this->_run_mod_handler('script_escape', true, $_tmp) : smarty_modifier_script_escape($_tmp)) ? $this->_run_mod_handler('h', true, $_tmp) : smarty_modifier_h($_tmp);
?>
</span>
<?php
if ((is_array($_tmp = @USE_POINT) ? $this->_run_mod_handler('script_escape', true, $_tmp) : smarty_modifier_script_escape($_tmp)) !== false) {
?>
/ Points: <span class="point"> <?php
echo is_array($_tmp = is_array($_tmp = is_array($_tmp = $this->_tpl_vars['tpl_user_point']) ? $this->_run_mod_handler('script_escape', true, $_tmp) : smarty_modifier_script_escape($_tmp)) ? $this->_run_mod_handler('number_format', true, $_tmp) : number_format($_tmp)) ? $this->_run_mod_handler('default', true, $_tmp, 0) : smarty_modifier_default($_tmp, 0);
?>
pts</span>
<?php
}
if (!(is_array($_tmp = $this->_tpl_vars['tpl_disable_logout']) ? $this->_run_mod_handler('script_escape', true, $_tmp) : smarty_modifier_script_escape($_tmp))) {
?>
<button class="bt02" onclick="fnFormModeSubmit('header_login_form', 'logout', '', ''); return false;">Log out</button><?php
}
?>
</p>
<?php
} else {
?>
<ul class="formlist clearfix">
<li class="mail">
示例7: smarty_core_load_plugins
<?php
/* Smarty version 2.6.0, created on 2010-05-19 18:24:37
compiled from docblock.tpl */
require_once SMARTY_DIR . 'core' . DIRECTORY_SEPARATOR . 'core.load_plugins.php';
smarty_core_load_plugins(array('plugins' => array(array('modifier', 'default', 'docblock.tpl', 1, false))), $this);
if ($this->_tpl_vars['sdesc'] != '') {
echo is_array($_tmp = @$this->_tpl_vars['sdesc']) ? $this->_run_mod_handler('default', true, $_tmp, '') : smarty_modifier_default($_tmp, '');
?>
<br /><br /><?php
}
if ($this->_tpl_vars['desc'] != '') {
echo is_array($_tmp = @$this->_tpl_vars['desc']) ? $this->_run_mod_handler('default', true, $_tmp, '') : smarty_modifier_default($_tmp, '');
?>
<br /><?php
}
if (count($this->_tpl_vars['tags']) > 0) {
?>
<br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
<?php
if (isset($this->_sections['tag'])) {
unset($this->_sections['tag']);
}
$this->_sections['tag']['name'] = 'tag';
$this->_sections['tag']['loop'] = is_array($_loop = $this->_tpl_vars['tags']) ? count($_loop) : max(0, (int) $_loop);
unset($_loop);
$this->_sections['tag']['show'] = true;
$this->_sections['tag']['max'] = $this->_sections['tag']['loop'];
示例8: smarty_function_checked
/> 男
<input name="sex" type="radio" value="woman" <?php
echo smarty_function_checked(array('val' => $_smarty_tpl->getVariable('edit')->value['sex'], 'str' => 'woman'), $_smarty_tpl->smarty, $_smarty_tpl);
?>
/> 女
</td>
</tr>
<tr>
<td align="right">备注</td>
<td><textarea name="remark" style="width:80%; height:120px"><?php
echo smarty_function_br_to_null(array('str' => $_smarty_tpl->getVariable('edit')->value['remark']), $_smarty_tpl->smarty, $_smarty_tpl);
?>
</textarea></td>
</tr>
<tr><th colspan="2" align="center"><input type="submit" value=" 提 交 " /> <input type="reset" value=" 重 填 " /></th></tr>
</table>
</form>
</div>
</div>
<b class="clear"></b>
</div>
<script type="text/javascript" src="Js/city.js"></script>
<script type="text/javascript">set_PROVINCE_CITY('PROVINCE_CITY' , 'province' , 'city' , '<?php
echo smarty_modifier_default($_smarty_tpl->getVariable('edit')->value['province'], "0");
?>
' , '<?php
echo smarty_modifier_default($_smarty_tpl->getVariable('edit')->value['city'], "0");
?>
');</script>
</body>
</html>
开发者ID:Capitalwang,项目名称:shehuahk,代码行数:31,代码来源:68332a3c4c792c3e145e46280be795adb9ec9dfb.file.service_append.html.php
示例9: smarty_function_translate
<a class="cancel" href="#"><?php
echo smarty_function_translate(array('text' => '_cancel'), $this);
?>
</a>
</fieldset>
<script type="text/javascript">
<?php
echo '
if(';
echo $this->_tpl_vars['someUser']['ID'];
echo ' > 0)
{
Backend.UserGroup.prototype.treeBrowser.selectItem(';
echo is_array($_tmp = @$this->_tpl_vars['someUser']['UserGroup']['ID']) ? $this->_run_mod_handler('default', true, $_tmp, -1) : smarty_modifier_default($_tmp, -1);
echo ', false);
Backend.User.Editor.prototype.getInstance(';
echo $this->_tpl_vars['someUser']['ID'];
echo ');
}
else
{
// Backend.User.Add.prototype.getInstance(';
echo $this->_tpl_vars['someUser']['UserGroup']['ID'];
echo ');
}
';
?>
</script>
示例10: smarty_modifier_t_escape
echo '][]" id="profile-';
echo smarty_modifier_t_escape($this->_tpl_vars['profile']['name']);
echo '-';
echo smarty_modifier_t_escape($this->_tpl_vars['item']['c_profile_option_id']);
echo '" value="';
echo smarty_modifier_t_escape($this->_tpl_vars['item']['c_profile_option_id']);
echo '"';
if ($this->_tpl_vars['c_member']['profile'][$this->_tpl_vars['profile']['name']]['value'] && in_array($this->_tpl_vars['item']['value'], $this->_tpl_vars['c_member']['profile'][$this->_tpl_vars['profile']['name']]['value'])) {
echo ' checked="checked"';
}
echo ' /><label for="profile-';
echo smarty_modifier_t_escape($this->_tpl_vars['profile']['name']);
echo '-';
echo smarty_modifier_t_escape($this->_tpl_vars['item']['c_profile_option_id']);
echo '">';
echo is_array($_tmp = smarty_modifier_t_escape($this->_tpl_vars['item']['value'])) ? $this->_run_mod_handler('default', true, $_tmp, "--") : smarty_modifier_default($_tmp, "--");
echo '</label></div></li>';
if ($this->_tpl_vars['_cnt'] % 3 == 0) {
echo '</ul>';
}
echo '';
}
}
unset($_from);
echo '';
if ($this->_tpl_vars['_cnt'] % 3 != 0) {
echo '</ul>';
}
echo '</div>';
}
echo '';
开发者ID:KimuraYoichi,项目名称:PukiWiki,代码行数:31,代码来源:dft_pc_templates^%%1F^1F9^1F90B399%%h_config_prof.tpl.php
示例11: is_array
<td class="paddingT15 wordSpacing5"><input class="infoTableInput2" name="pluginvar[height]" value="<?php
echo is_array($_tmp = @$this->_tpl_vars['height']) ? $this->_run_mod_handler('default', true, $_tmp, 500) : smarty_modifier_default($_tmp, 500);
?>
" />px</td>
</tr>
<tr>
<th class="paddingT15"> 默认纬度:</th>
<td class="paddingT15 wordSpacing5"><input class="infoTableInput2" name="pluginvar[lat]" value="<?php
echo is_array($_tmp = @$this->_tpl_vars['lat']) ? $this->_run_mod_handler('default', true, $_tmp, '29.264911735066963') : smarty_modifier_default($_tmp, '29.264911735066963');
?>
" /></td>
</tr>
<tr>
<th class="paddingT15"> 默认经度:</th>
<td class="paddingT15 wordSpacing5"><input class="infoTableInput2" name="pluginvar[lng]" value="<?php
echo is_array($_tmp = @$this->_tpl_vars['lng']) ? $this->_run_mod_handler('default', true, $_tmp, '120.24544715881347') : smarty_modifier_default($_tmp, '120.24544715881347');
?>
" /></td>
</tr>
<tr>
<th></th>
<td class="ptb20">
<input class="formbtn" type="submit" name="save" id="Save" value="保存配置" /> [<a href="<?php
echo $this->_tpl_vars['SiteUrl'];
?>
plugin.php?name=<?php
echo $this->_tpl_vars['name'];
?>
" target="_blank">预览插件</a>]</td>
</tr>
</table>
示例12: smarty_function_html_options
<div id="folder_list" style="display:none;">
<?php
echo smarty_function_html_options(array('name' => 'chg_folder_id', 'options' => $this->_tpl_vars['infoDispPositionForSelectList'], 'selected' => is_array($_tmp = @$this->_tpl_vars['param']['folder_id']) ? $this->_run_mod_handler('default', true, $_tmp, 1) : smarty_modifier_default($_tmp, 1)), $this);
?>
に移動
</div>
<div id="chg_display" style="display:none;">
<?php
echo smarty_function_html_options(array('name' => 'chg_display_id', 'options' => $this->_tpl_vars['isDisplay'], 'selected' => 0), $this);
?>
に変更
</div>
<div id="info_copy" style="display:none;">
コピー数: <?php
echo smarty_function_html_options(array('name' => 'info_copy_number', 'options' => $this->_tpl_vars['selectCopyNumber'], 'selected' => is_array($_tmp = @$this->_tpl_vars['param']['info_copy_number']) ? $this->_run_mod_handler('default', true, $_tmp, 0) : smarty_modifier_default($_tmp, 0)), $this);
?>
</div>
</td>
</tr>
<tr>
<td style="text-align:center;" colspan="2">
<input type="submit" name="action_informationStatus_InformationExec" value="更新" onClick="return confirm('更新しますか?')">
</td>
</tr>
</table>
<br>
<table border="0" cellspacing="0" cellpadding="0" id="list_table" class="TableSet04">
<tr bgcolor="#FF9933">
<th rowspan="2"><a href="<?php
示例13: smarty_modifier_default
</tr>
<tr>
<td align="right">净度</td>
<td><?php
echo $_smarty_tpl->getVariable('edit')->value['clarity'];
?>
</td>
</tr>
<tr>
<td align="right">颜色</td>
<td><?php
echo $_smarty_tpl->getVariable('edit')->value['color'];
?>
</td>
</tr>
<tr>
<td align="right" class="Need">价格(美元)</td>
<td><input type="text" name="price" value="<?php
echo smarty_modifier_default($_smarty_tpl->getVariable('edit')->value['price'], 0.0);
?>
" style="width:150px" /></td>
</tr>
<tr><th colspan="2" align="center"><input type="submit" value=" 提 交 " /> <input type="reset" value=" 重 填 " /></th></tr>
</table>
</form>
</div>
</div>
<b class="clear"></b>
</div>
</body>
</html>
开发者ID:Capitalwang,项目名称:shehuahk,代码行数:31,代码来源:6ebc86f4109f052412abf609e9a28c373df73e81.file.bid_append.html.php
示例14: unset
}
unset($_from);
?>
<tr class="BgColor02">
<td colspan="2"><center><b>月間合計</b></center></td>
<?php
$_from = $this->_tpl_vars['roiTotalForMonthly'];
if (!is_array($_from) && !is_object($_from)) {
settype($_from, 'array');
}
$this->_foreach['loop'] = array('total' => count($_from), 'iteration' => 0);
if ($this->_foreach['loop']['total'] > 0) {
foreach ($_from as $this->_tpl_vars['roiMonthly'] => $this->_tpl_vars['roiMonthTotalMonth']) {
$this->_foreach['loop']['iteration']++;
?>
<td><?php
echo is_array($_tmp = @$this->_tpl_vars['roiMonthTotalMonth']) ? $this->_run_mod_handler('default', true, $_tmp, 0) : smarty_modifier_default($_tmp, 0);
?>
%</td>
<?php
}
}
unset($_from);
?>
<td><?php
echo $this->_tpl_vars['roiTotal'];
?>
%</td>
</tr>
</table>
示例15: is_array
?>
<meta http-equiv="expires" content="0" />
<meta http-equiv="cache-control" content="no-cache" />
<meta http-equiv="pragma" content="no-cache" />
<?php
}
?>
<link rel="shortcut icon" href="favicon.ico" />
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<meta name="robots" content="index" />
<meta name="robots" content="follow" />
<link rel="stylesheet" type="text/css" href="<?php
echo is_array($_tmp = @$this->_tpl_vars['RootPath']) ? $this->_run_mod_handler('default', true, $_tmp, '') : smarty_modifier_default($_tmp, '');
?>
styles/<?php
echo is_array($_tmp = @$this->_tpl_vars['StyleSheet']) ? $this->_run_mod_handler('default', true, $_tmp, 'standard.css') : smarty_modifier_default($_tmp, 'standard.css');
?>
" />
<?php
echo $this->_tpl_vars['CSSExtra'];
?>
<?php
echo $this->_tpl_vars['JavaScript'];
?>
<?php
echo $this->_tpl_vars['xajax'];
?>
</head>