mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-05-22 05:15:29 +09:00
NOISSUE, trivial code change
This commit is contained in:
parent
b3b7f0aed8
commit
27cf174b0c
2 changed files with 16 additions and 38 deletions
|
|
@ -51,14 +51,13 @@ class ExtraVar
|
||||||
*/
|
*/
|
||||||
function setExtraVarKeys($extra_keys)
|
function setExtraVarKeys($extra_keys)
|
||||||
{
|
{
|
||||||
if(!is_array($extra_keys) || !count($extra_keys))
|
if(!is_array($extra_keys) || count($extra_keys) < 1)
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
foreach($extra_keys as $key => $val)
|
foreach($extra_keys as $val)
|
||||||
{
|
{
|
||||||
$obj = null;
|
|
||||||
$obj = new ExtraItem($val->module_srl, $val->idx, $val->name, $val->type, $val->default, $val->desc, $val->is_required, $val->search, $val->value, $val->eid);
|
$obj = new ExtraItem($val->module_srl, $val->idx, $val->name, $val->type, $val->default, $val->desc, $val->is_required, $val->search, $val->value, $val->eid);
|
||||||
$this->keys[$val->idx] = $obj;
|
$this->keys[$val->idx] = $obj;
|
||||||
}
|
}
|
||||||
|
|
@ -226,9 +225,6 @@ class ExtraItem
|
||||||
$values = explode(',', $value);
|
$values = explode(',', $value);
|
||||||
}
|
}
|
||||||
|
|
||||||
$values[0] = $values[0];
|
|
||||||
$values[1] = $values[1];
|
|
||||||
$values[2] = $values[2];
|
|
||||||
return $values;
|
return $values;
|
||||||
|
|
||||||
case 'checkbox' :
|
case 'checkbox' :
|
||||||
|
|
@ -251,7 +247,7 @@ class ExtraItem
|
||||||
$values = array($value);
|
$values = array($value);
|
||||||
}
|
}
|
||||||
|
|
||||||
for($i = 0; $i < count($values); $i++)
|
for($i = 0, $c = count($values); $i < $c; $i++)
|
||||||
{
|
{
|
||||||
$values[$i] = htmlspecialchars($values[$i], ENT_COMPAT | ENT_HTML401, 'UTF-8', false);
|
$values[$i] = htmlspecialchars($values[$i], ENT_COMPAT | ENT_HTML401, 'UTF-8', false);
|
||||||
}
|
}
|
||||||
|
|
@ -315,10 +311,7 @@ class ExtraItem
|
||||||
{
|
{
|
||||||
return implode(', ', $value);
|
return implode(', ', $value);
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
return $value;
|
return $value;
|
||||||
}
|
|
||||||
|
|
||||||
case 'date' :
|
case 'date' :
|
||||||
return zdate($value, "Y-m-d");
|
return zdate($value, "Y-m-d");
|
||||||
|
|
@ -329,20 +322,14 @@ class ExtraItem
|
||||||
{
|
{
|
||||||
return implode(', ', $value);
|
return implode(', ', $value);
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
return $value;
|
return $value;
|
||||||
}
|
|
||||||
|
|
||||||
case 'kr_zip' :
|
case 'kr_zip' :
|
||||||
if(is_array($value))
|
if(is_array($value))
|
||||||
{
|
{
|
||||||
return implode(' ', $value);
|
return implode(' ', $value);
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
return $value;
|
return $value;
|
||||||
}
|
|
||||||
|
|
||||||
// case 'text' :
|
// case 'text' :
|
||||||
default :
|
default :
|
||||||
|
|
|
||||||
|
|
@ -8,6 +8,8 @@
|
||||||
class FrontEndFileHandler extends Handler
|
class FrontEndFileHandler extends Handler
|
||||||
{
|
{
|
||||||
|
|
||||||
|
static $isSSL = FALSE;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Map for css
|
* Map for css
|
||||||
* @var array
|
* @var array
|
||||||
|
|
@ -51,22 +53,15 @@ class FrontEndFileHandler extends Handler
|
||||||
*/
|
*/
|
||||||
function isSsl()
|
function isSsl()
|
||||||
{
|
{
|
||||||
if($GLOBAL['__XE_IS_SSL__'])
|
if(self::$isSSL)
|
||||||
{
|
{
|
||||||
return $GLOBAL['__XE_IS_SSL__'];
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
$url_info = parse_url(Context::getRequestUrl());
|
$url_info = parse_url(Context::getRequestUrl());
|
||||||
if($url_info['scheme'] == 'https')
|
self::$isSSL = ($url_info['scheme'] == 'https');
|
||||||
{
|
|
||||||
$GLOBAL['__XE_IS_SSL__'] = TRUE;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
$GLOBAL['__XE_IS_SSL__'] = FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
return $GLOBAL['__XE_IS_SSL__'];
|
return self::$isSSL;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -115,8 +110,7 @@ class FrontEndFileHandler extends Handler
|
||||||
}
|
}
|
||||||
else if($file->fileExtension == 'js')
|
else if($file->fileExtension == 'js')
|
||||||
{
|
{
|
||||||
$type = $args[1];
|
if($args[1] == 'body')
|
||||||
if($type == 'body')
|
|
||||||
{
|
{
|
||||||
$map = &$this->jsBodyMap;
|
$map = &$this->jsBodyMap;
|
||||||
$mapIndex = &$this->jsBodyMapIndex;
|
$mapIndex = &$this->jsBodyMapIndex;
|
||||||
|
|
@ -222,8 +216,7 @@ class FrontEndFileHandler extends Handler
|
||||||
if(isset($this->cssMapIndex[$file->key]))
|
if(isset($this->cssMapIndex[$file->key]))
|
||||||
{
|
{
|
||||||
$index = $this->cssMapIndex[$file->key];
|
$index = $this->cssMapIndex[$file->key];
|
||||||
unset($this->cssMap[$index][$file->key]);
|
unset($this->cssMap[$index][$file->key], $this->cssMapIndex[$file->key]);
|
||||||
unset($this->cssMapIndex[$file->key]);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
@ -231,14 +224,12 @@ class FrontEndFileHandler extends Handler
|
||||||
if(isset($this->jsHeadMapIndex[$file->key]))
|
if(isset($this->jsHeadMapIndex[$file->key]))
|
||||||
{
|
{
|
||||||
$index = $this->jsHeadMapIndex[$file->key];
|
$index = $this->jsHeadMapIndex[$file->key];
|
||||||
unset($this->jsHeadMap[$index][$file->key]);
|
unset($this->jsHeadMap[$index][$file->key], $this->jsHeadMapIndex[$file->key]);
|
||||||
unset($this->jsHeadMapIndex[$file->key]);
|
|
||||||
}
|
}
|
||||||
if(isset($this->jsBodyMapIndex[$file->key]))
|
if(isset($this->jsBodyMapIndex[$file->key]))
|
||||||
{
|
{
|
||||||
$index = $this->jsBodyMapIndex[$file->key];
|
$index = $this->jsBodyMapIndex[$file->key];
|
||||||
unset($this->jsBodyMap[$index][$file->key]);
|
unset($this->jsBodyMap[$index][$file->key], $this->jsBodyMapIndex[$file->key]);
|
||||||
unset($this->jsBodyMapIndex[$file->key]);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue