本文整理汇总了PHP中hee函数的典型用法代码示例。如果您正苦于以下问题:PHP hee函数的具体用法?PHP hee怎么用?PHP hee使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了hee函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: showInput
static function showInput($S)
{
$value = !$S->count() ? $S->get() : array();
switch ($S->getHandler()) {
case 'checkbox':
return '<input name="' . $S->i . '" type=checkbox ' . ($value ? 'checked' : '') . '>';
case 'select':
return '<select name="' . $S->i . '">' . helper_optionsFromArray($S->getOptions(), $value, 0) . '</select>';
case 'range':
$opts = $S->getOptions();
if (isset($opts[1])) {
// deprecated
$vs['min'] = $opts[0];
$vs['max'] = $opts[1];
if (isset($opts[2])) {
$vs['step'] = $opts[2];
}
} else {
$vs = $opts[0];
}
if (!isset($vs['step'])) {
$vs['step'] = 'any';
}
$atts = array();
foreach ($vs as $n => $v) {
$atts[] = $n . '="' . $v . '"';
}
return '<input name="' . $S->i . '" type=range ' . implode(' ', $atts) . ' value="' . hee($value) . '">';
case 'number':
$opts = $S->getOptions();
$vs = isset($opts[0]) ? $opts[0] : array();
if (!isset($vs['step'])) {
$vs['step'] = 'any';
}
$atts = array();
foreach ($vs as $n => $v) {
$atts[] = $n . '="' . $v . '"';
}
return '<input name="' . $S->i . '" type=number ' . implode(' ', $atts) . ' value="' . hee($value) . '">';
case 'text':
return '<textarea name="' . $S->i . '">' . hee($value) . '</textarea>';
default:
switch ($S->getType()) {
case 'bool':
return '<input type=checkbox name="' . $S->i . '" ' . ($value ? 'checked' : '') . '>';
case 'int':
return '<input type=number name="' . $S->i . '" value="' . hee($value) . '">';
default:
if (!is_array($value)) {
return '<input type=text name="' . $S->i . '" value="' . hee($value) . '">';
} else {
return '<input type=hidden name="' . $S->i . '">';
}
}
}
}
示例2: getHeader
static function getHeader()
{
$return = '<meta charset=utf-8>' . "\n";
$return .= '<title>' . hee(self::$titlePrefix . self::$title . self::$titleSuffix) . '</title>' . "\n";
$return .= self::$head;
foreach (self::$meta as $name => $value) {
if ($value === '') {
continue;
}
$return .= '<meta name=' . $name . ' content="' . $value . '">' . "\n";
}
$return .= self::_getHeaderCSSFiles();
$return .= self::_getHeaderJSFiles();
$return .= trim(self::$css) ? '<style>' . self::$css . '</style>' . "\n" : '';
return $return;
}
示例3: init
function init()
{
if (is_file(appPATH . 'qg/' . $this->mod . '/pub/main.js')) {
html::addJsFile(appURL . 'qg/' . $this->mod . '/pub/main.js');
}
html::addCssFile(appURL . 'qg/' . $this->mod . '/pub/base.css', 'dr8og', false);
html::addCssFile(appURL . 'qg/' . $this->mod . '/pub/custom.css', 'dr8og', false);
if ($gFont = $this->getLayoutPage()->SET['google-font']->v) {
$gFont = str_replace('|', '%7C', $gFont);
// rawurlencode ?
html::$head .= '<link rel=stylesheet href="' . hee($gFont) . '">';
}
if ($this->LPage->edit) {
html::addJsFile(sysURL . 'cms.layouter3/pub/qgElSty/qgCssProps.js', '43l5k');
html::addJsFile(sysURL . 'cms.layouter3/pub/qgElSty/q1CssText.js', '43l5k');
html::addJsFile(sysURL . 'cms.layouter3/pub/qgElSty/qgStyleEditor.js', '43l5k');
html::addJsFile(sysURL . 'cms.layouter3/pub/qgElSty/qgStyleSheetEditor.js', '43l5k');
html::addJsFile(sysURL . 'cms.layouter3/pub/qgElSty/spectrum.js', '43l5k');
html::addCssFile(sysURL . 'cms.layouter3/pub/qgElSty/spectrum.css', '43l5k', 0);
html::addCssFile(sysURL . 'cms.layouter3/pub/qgElSty/main.css', '43l5k');
html::addJsFile(sysURL . 'cms.layouter3/pub/plupload/js/plupload.full.js', '43l5k');
html::addJsFile(sysURL . 'cms.layouter3/pub/edit.js', '43l5k');
}
}
示例4: realpath
}
if (preg_match('/\\/Zend\\//', $search)) {
continue;
}
if (preg_match('/\\/cache\\//', $search)) {
continue;
}
if (!is_file($datei)) {
continue;
}
$file = realpath($datei);
$_SESSION['fileEditor']['allow'][$file] = 1;
$src = appURL . 'editor?file=' . urlencode($file);
?>
<tr><td><a href="<?php
echo hee($src);
?>
" target=<?php
echo md5($file);
?>
><?php
echo $show;
?>
</a><td><?php
echo strftime('%x %X', filemtime($file));
}
?>
</table>
</div>
</div>
示例5: foreach
</b>
<td>
<td>
<tbody>
<?php
foreach (D()->query("SELECT * FROM page_url WHERE page_id = '" . $Cont . "' ") as $vs) {
?>
<tr data-lang="<?php
echo $vs['lang'];
?>
">
<td><?php
echo $vs['lang'];
?>
<td style="border-right:none"><input class=-url type=text value="<?php
echo hee($vs['url']);
?>
" style="width:100%">
<td style="width:1px; border-left:none"><input class=-custom type=checkbox <?php
echo $vs['custom'] ? 'checked' : '';
?>
title=fix>
<td style="width:10px"><input class=-target <?php
echo $vs['target'] ? 'checked' : '';
?>
type=checkbox title="<?php
echo L('Neues Fenster');
?>
">
<?php
}
示例6: hee
<?php
$separator = hee($Cont->SET['breadcrumb separator']->v);
$separator = str_replace(' ', ' ', $separator);
$separator = $separator ? $separator : ' - ';
$previewImage = $Cont->SET['preview image']->setType('bool')->v;
if ($previewImage) {
$previewImageQuery = $Cont->SET->make('preview image query', '/w-120/h-400/max/')->v;
}
foreach ($res as $id => $r) {
$C = Page($id);
$P = $C->Page;
$href = $C->url();
?>
<div class=-item>
<?php
if ($previewImage) {
foreach ($C->Files() as $F) {
if (!image::able($F->path)) {
continue;
}
echo '<a href="' . $href . '"><img src="' . $F->url() . '/' . $previewImageQuery . '/' . $F->name() . '"></a>';
break;
}
}
?>
<a href="<?php
echo $href;
?>
示例7: hee
if ($value !== false) {
$checked = $value === $v ? ' checked ' : '';
}
echo '<label><input type=checkbox id="l' . $id . '" name="' . $id . '"' . $required . $checked . ' value="' . hee($v) . '"> ' . $Cont->text($id . '_value') . '</label>';
break;
case 'radio':
foreach (explode(';', $Cont->text($id . '_value')) as $option) {
$option = hee(trim($option));
$checked = $value === $option ? ' checked' : '';
echo '<label><input type=radio value="' . $option . '" name="' . $id . '"' . $required . $checked . '> ' . preg_replace('/\\([^)]\\)$/', '', $option) . ' </label>';
}
break;
case 'select':
echo '<select id="l' . $id . '" name="' . $id . '"' . $required . '>';
foreach (explode(';', $Cont->text($id . '_value')) as $option) {
$option = hee(trim($option));
echo '<option value="' . $option . '" ' . ($value === $option ? 'selected' : '') . '>' . preg_replace('/\\([^)]\\)$/', '', $option) . '</option>';
}
echo '</select>';
break;
case 'description':
$T = $Cont->text($id . '_desc');
echo '<div ' . ($Cont->edit ? 'contenteditable cmstxt=' . $T->id : '') . '>' . $T . '</div>';
break;
case 'email':
echo '<input value="' . $value . '" type=email class=input id="l' . $id . '" name="' . $id . '"' . $required . '>';
break;
case 'url':
echo '<input value="' . $value . '" type=url class=input id="l' . $id . '" name="' . $id . '"' . $required . '>';
break;
default:
示例8: foreach
if (!$cl || isset($classes[$cl])) {
continue;
}
$classes[$cl] = $vs;
}
?>
<?php
foreach ($classes as $class => $vs) {
?>
<label style="min-width:80px; flex-basis:auto; margin:1px; background:#fff; padding:3px; border:1px solid #eee; cursor:pointer; border-radius:3px ">
<input type=checkbox <?php
echo !isset($vs['count']) ? 'checked' : '';
?>
class="-added" style="vertical-align:bottom;">
<span><?php
echo hee($class);
?>
</span>
</label>
<?php
}
?>
</div>
</div>
<script>
$('.qgCmsPageClasses').on('change','.-added', function() {
var fn = this.checked?'addClass':'removeClass';
$fn('page::'+fn)(<?php
echo $Cont;
?>
示例9: L
if (G()->SET->has($M->name) || G()->SET['m']->has($M->name)) {
?>
<img src="<?php
echo sysURL;
?>
cms/pub/css/pix/settings.png" title="<?php
echo L('Einstellungen');
?>
" style="vertical-align:middle" alt=Einstellungen>
<?php
}
?>
</a>
<td>
<input value="<?php
echo hee($M->Title());
?>
" onchange="moduleSetTitle(this,'<?php
echo $M;
?>
')">
<td>
<?php
if (preg_match('/^cms\\.(backend|cont|layout)\\./', $M->name)) {
echo D()->one("SELECT count(*) FROM page WHERE module = " . D()->quote($M->name));
}
?>
<td style="text-align:center">
<input onclick="moduleSetAccess(this,'<?php
echo $M;
?>
示例10: foreach
}
?>
<table style="width:100%" class=noWrap>
<?php
foreach ($Ls as $pid => $L) {
?>
<tr>
<td>
<?php
echo qgCms_link($pid);
?>
<td style="width:160px; color:<?php
echo Usr()->id == $L->sess()->usr()->id ? 'red' : '';
?>
" title="<?php
echo hee($L->sess()->usr()->firstname . ' ' . $L->sess()->usr()->lastname);
?>
">
<?php
echo $L->sess()->usr()->email;
?>
<?php
$d = strftime('%d', $L->time);
$m = strftime('%m', $L->time);
$Y = strftime('%Y', $L->time);
$H = strftime('%H', $L->time);
$M = strftime('%M', $L->time);
$nd = strftime('%d');
$nm = strftime('%m');
$nY = strftime('%Y');
$nH = strftime('%H');
示例11: logDetails
static function logDetails($id)
{
$id = (int) $id;
$row = D()->row("SELECT * FROM log WHERE id = " . $id);
if ($row['post']) {
$post = unserialize($row['post']);
$ask = $post['askJSON'];
$data = json_decode($ask, 1);
$translateFn = array('page::addContent' => 'Inhalt hinzugefügt', 'page::insertBefore' => 'Position geändert', 'page::setDefault' => 'Einstellung geändert', 'page::FilesSort' => 'Dateireihenfolge geändet', 'page::addDbFile' => 'Datei hinzugefügt', 'page::copy' => 'Kopiert', 'page::remove' => 'Gelöscht.');
$ContOrPage = function ($Page) {
$title = trim(strip_tags($Page->Title()));
$title = $title ? '"' . $title . '"' : '';
return ($Page->vs['type'] === 'p' ? 'Seite' : 'Inhalt') . ' ' . $title . ' (' . $Page->id . ') :<br>';
};
$messages = array();
foreach ($data['serverInterface'] as $call) {
$fn = $call['fn'];
$args = $call['args'];
if ($fn === 'cms::getTree' || $fn === 'page::getWidgetContent' || $fn === 'Setting' || $fn === 'page::reload') {
continue;
}
if (strpos($fn, 'page::') === 0) {
$Page = Page($args[0]);
$messages[] = $ContOrPage($Page) . ' ' . (isset($translateFn[$fn]) ? $translateFn[$fn] : $fn);
} else {
if ($fn === 'cms::setTxt') {
if ($vs = D()->row("SELECT name, page_id FROM page_text WHERE text_id = " . (int) $args[0] . " ")) {
$Page = Page($vs['page_id']);
$messages[] = $ContOrPage($Page) . ' Text "' . hee($vs['name']) . '" geändert';
} else {
if ($vs = D()->row("SELECT id FROM page WHERE title_id = " . (int) $args[0] . " ")) {
$Page = Page($vs['id']);
$messages[] = $ContOrPage($Page) . ' Titel geändert';
}
}
} else {
if ($fn === 'cms_vers::rollBackCont') {
$Page = Page($args[0]);
$messages[] = $ContOrPage($Page) . ' Stand zurückgesetzt';
} else {
$messages[] = $fn;
}
}
}
}
$Log = D()->log->Entry($row);
$Sess = Sess($Log->sess_id);
$Usr = $Sess->Usr();
$Client = D()->client->Entry($Sess->client_id);
$email = $Usr->is() ? $Usr->email : 'guest';
$ua = $Client->browser;
// ua to browser
$str = $ua;
$str = preg_replace('/Trident.+rv:([0-9.]+)/', 'IE/$1', $str);
$str = preg_replace('/Version\\/([0-9.]+).+Safari\\/([0-9.]+).+/', 'Safari/$1', $str);
$str = preg_replace('/MSIE ([0-9.]+)/', 'IE/$1', $str);
$str = preg_replace('/Edge\\//', 'IE/', $str);
$str = preg_replace('/(Mozilla|AppleWebKit|Trident|Gecko)\\//', '', $str);
preg_match('/([a-zA-Z]+)\\/([0-9]+\\.[0-9])/', $str, $matches);
if ($matches) {
list($x, $vendor, $version) = $matches;
$browser = $vendor . ' ' . $version;
} else {
$browser = 'other';
}
return array('messages' => $messages, 'usr' => $email, 'url' => $Log->url, 'referer' => $Log->referer, 'ip' => $Sess->ip, 'browser' => $browser, 'time' => strftime('<b>%x</b> %H:%M', $Log->time), 'user_agent' => $ua);
}
//$log = D()->row;
}
示例12: foreach
<?php
namespace qg;
if ($Cont->access() < 2) {
return;
}
?>
<table id=qgCmsTxtsWindow>
<?php
foreach ($Cont->texts() as $name => $T) {
?>
<tr>
<td><?php
echo hee($name);
?>
<td style="width:70%"><div class=-txt cmstxt=<?php
echo $T->id;
?>
contenteditable><?php
echo $T;
?>
</div>
<?php
}
?>
</table>
<style>
示例13: L
" style="background-image:url(<?php
echo sysURL;
?>
cms/pub/css/pix/backend.png)">
<?php
echo L('zum Backend');
?>
<span>[B]</span>
</a>
<li>
<a show=login style="background-image:url(<?php
echo sysURL;
?>
cms/pub/css/pix/users.png)">
<?php
echo hee(Usr()->firstname . ' ' . Usr()->lastname);
?>
</a>
<li>
<a show=help style="background-image:url(<?php
echo sysURL;
?>
cms/pub/css/pix/help.png)">
<?php
echo L('Hilfe');
?>
</a>
<li>
<a href="<?php
echo Url()->addParam('liveUser_logout', 1);
?>
示例14: L
e.target.focus();
})
</script>
<tr>
<th style="text-align:left"><?php
echo L('Inhalt der Datei');
?>
:
<td><textarea onchange="$fn('page::fileSetText')(<?php
echo $Cont;
?>
,'<?php
echo $param['name'];
?>
', this.value).run()" style="width:100%; height:200px"><?php
echo hee($F->vs['text']);
?>
</textarea>
<tr>
<th style="text-align:left"><?php
echo L('Grösse');
?>
:
<td><?php
echo byte_format($F->size());
?>
<tr class="expert">
<th style="text-align:left">Mime:
<td>
<input value="<?php
echo $F->mime();
示例15: hee
<form method=post>
<?php
if ($Cont->SET['saveLogin']->v) {
?>
<input name=save_login type=checkbox value=1 <?php
echo $ClientUsr->save_login ? 'checked' : '';
?>
>
<?php
}
?>
<?php
echo hee($Usr->email);
?>
<input name=email type=hidden value="<?php
echo hee($Usr->email);
?>
">
<?php
if (!$ClientUsr->save_login) {
?>
<input name=pw type=password>
<?php
}
?>
<input name=liveUser_login type=submit value=login>
</form>
<?php
}
?>