Merge pull request #378 from smaker/php54

PHP 5.4에서 발생하는 호환성 문제 수정
This commit is contained in:
sungbum hong 2014-01-28 02:04:44 -08:00
commit 6a1614f396
5 changed files with 18 additions and 1 deletions

View file

@ -255,7 +255,16 @@ class addonAdminModel extends addon
foreach($extra_vars as $key => $val)
{
if(!$val)
{
continue;
}
$obj = new stdClass();
if(!$val->attrs)
{
$val->attrs = new stdClass();
}
if(!$val->attrs->type)
{
$val->attrs->type = 'text';
@ -341,6 +350,11 @@ class addonAdminModel extends addon
$addon_info->extra_vars = array();
foreach($extra_vars as $key => $val)
{
if(!$val)
{
continue;
}
$obj = new stdClass();
$obj->group = $group->title->body;

View file

@ -196,7 +196,7 @@ class installAdminController extends install
$ftp_info->ftp_password = Context::get('ftp_password');
}
$buff = '<?php if(!defined("__XE__")) exit();'."\n";
$buff = '<?php if(!defined("__XE__")) exit();'."\n\$ftp_info = new stdClass;\n";
foreach($ftp_info as $key => $val)
{
if(!$val) continue;

View file

@ -892,6 +892,7 @@ class memberModel extends member
if(file_exists($image_name_file))
{
list($width, $height, $type, $attrs) = getimagesize($image_name_file);
$info = new stdClass;
$info->width = $width;
$info->height = $height;
$info->src = Context::getRequestUri().$image_name_file;

View file

@ -23,6 +23,7 @@ class menuMobile extends moduleObject
function straightenMenu($menu_item, $depth)
{
if(!$menu_item['link']) return;
$obj = new stdClass;
$obj->href = $menu_item['href'];
$obj->depth = $depth;
$obj->text = $menu_item['text'];

View file

@ -667,6 +667,7 @@ class widgetController extends widget
$widgetstyle_info = $oWidgetModel->getWidgetStyleInfo($widgetStyle);
if(!$widgetstyle_info) return $widget_content_body;
$widgetstyle_extra_var = new stdClass();
$widgetstyle_extra_var_key = get_object_vars($widgetstyle_info);
if(count($widgetstyle_extra_var_key['extra_var']))
{