diff --git a/classes/display/DisplayHandler.class.php b/classes/display/DisplayHandler.class.php
index 6f880ba86..a4551764f 100644
--- a/classes/display/DisplayHandler.class.php
+++ b/classes/display/DisplayHandler.class.php
@@ -175,27 +175,27 @@ class DisplayHandler extends Handler
{
$data = Rhymix\Framework\Debug::getDebugData();
$display_content = array_fill_keys(config('debug.display_content'), true);
- if (count($display_content) && !isset($display_content['entries']))
+ if (!isset($display_content['entries']))
{
$data->entries = null;
}
- if (count($display_content) && !isset($display_content['queries']))
+ if (!isset($display_content['queries']))
{
unset($data->queries);
}
- if (count($display_content) && !isset($display_content['slow_queries']))
+ if (!isset($display_content['slow_queries']))
{
unset($data->slow_queries);
}
- if (count($display_content) && !isset($display_content['slow_triggers']))
+ if (!isset($display_content['slow_triggers']))
{
unset($data->slow_triggers);
}
- if (count($display_content) && !isset($display_content['slow_widgets']))
+ if (!isset($display_content['slow_widgets']))
{
unset($data->slow_widgets);
}
- if (count($display_content) && !isset($display_content['slow_remote_requests']))
+ if (!isset($display_content['slow_remote_requests']))
{
unset($data->slow_remote_requests);
}
diff --git a/common/constants.php b/common/constants.php
index bb9b12254..c818f27ff 100644
--- a/common/constants.php
+++ b/common/constants.php
@@ -117,6 +117,11 @@ else
define('RX_POST', false);
}
+/**
+ * RX_WINDOWS is true if the operating system is Windows.
+ */
+define('RX_WINDOWS', strncasecmp(PHP_OS, 'WIN', 3) === 0);
+
/**
* XE core compatibility constants (may be used by XE-compatible plugins and themes).
*/
diff --git a/common/defaults/config.php b/common/defaults/config.php
index 05fc33d57..abc96e02a 100644
--- a/common/defaults/config.php
+++ b/common/defaults/config.php
@@ -88,13 +88,13 @@ return array(
),
'debug' => array(
'enabled' => true,
- 'log_slow_queries' => 0,
- 'log_slow_triggers' => 0,
- 'log_slow_widgets' => 0,
- 'log_slow_remote_requests' => 0,
+ 'log_slow_queries' => 0.25,
+ 'log_slow_triggers' => 0.25,
+ 'log_slow_widgets' => 0.25,
+ 'log_slow_remote_requests' => 1.25,
'log_filename' => null,
'display_type' => array('comment'),
- 'display_content' => array(),
+ 'display_content' => array('request_info', 'entries', 'errors', 'queries'),
'display_to' => 'admin',
'write_error_log' => 'fatal',
'allow' => array(),
diff --git a/common/framework/security.php b/common/framework/security.php
index 29de721d4..2663e1186 100644
--- a/common/framework/security.php
+++ b/common/framework/security.php
@@ -198,20 +198,19 @@ class Security
// Use other good sources of entropy if random_bytes() is not available.
if ($entropy === false)
{
- $is_windows = (defined('\PHP_OS') && strtoupper(substr(\PHP_OS, 0, 3)) === 'WIN');
if(function_exists('openssl_random_pseudo_bytes'))
{
$entropy = openssl_random_pseudo_bytes($entropy_capped_bytes);
}
- elseif(function_exists('mcrypt_create_iv') && !$is_windows)
+ elseif(function_exists('mcrypt_create_iv') && !\RX_WINDOWS)
{
$entropy = mcrypt_create_iv($entropy_capped_bytes, \MCRYPT_DEV_URANDOM);
}
- elseif(function_exists('mcrypt_create_iv') && $is_windows)
+ elseif(function_exists('mcrypt_create_iv') && \RX_WINDOWS)
{
$entropy = mcrypt_create_iv($entropy_capped_bytes, \MCRYPT_RAND);
}
- elseif(!$is_windows && @is_readable('/dev/urandom'))
+ elseif(!\RX_WINDOWS && @is_readable('/dev/urandom'))
{
$fp = fopen('/dev/urandom', 'rb');
if (function_exists('stream_set_read_buffer')) // This function does not exist in HHVM.
diff --git a/common/framework/storage.php b/common/framework/storage.php
index d864fd50e..cd01594d1 100644
--- a/common/framework/storage.php
+++ b/common/framework/storage.php
@@ -152,7 +152,7 @@ class Storage
public static function isExecutable($path)
{
$path = rtrim($path, '/\\');
- if (function_exists('exec'))
+ if (function_exists('exec') && !\RX_WINDOWS)
{
@exec('/bin/ls -l ' . escapeshellarg($path), $output, $return_var);
if ($return_var === 0)
@@ -880,7 +880,7 @@ class Storage
public static function recommendUmask()
{
// On Windows, set the umask to 0000.
- if (strncasecmp(\PHP_OS, 'Win', 3) === 0)
+ if (\RX_WINDOWS)
{
return '0000';
}
diff --git a/common/legacy.php b/common/legacy.php
index 78f3f7d83..9790fab84 100644
--- a/common/legacy.php
+++ b/common/legacy.php
@@ -1309,7 +1309,7 @@ function closePopupScript()
function reload($isOpener = FALSE)
{
$reloadScript = $isOpener ? 'window.opener.location.reload();' : 'window.location.reload();';
- echo sprintf('', $raloadScript);
+ echo sprintf('', $reloadScript);
}
/* End of file func.inc.php */
diff --git a/common/tpl/debug_comment.html b/common/tpl/debug_comment.html
index e3213c2ba..2b4c3d99f 100644
--- a/common/tpl/debug_comment.html
+++ b/common/tpl/debug_comment.html
@@ -2,7 +2,7 @@
timestamp . ']' . "\n"; ?>
-
+
Request / Response
==================
Request URL: url . "\n"; ?>
@@ -30,7 +30,7 @@ Peak Memory Usage:
-
+
Debug Entries
=============
-
+
PHP Errors and Warnings
=======================
-
+
Database Queries
================
-
+
Slow Queries
============
-
+
Slow Triggers
=============
-
+
Slow Widgets
============
-
+
Slow Remote Requests
====================
debug_write_error_log) ?: 'fatal');
// Debug content
- $debug_content = array_values($vars->debug_display_content);
+ $debug_content = array_values($vars->debug_display_content ?: array());
Rhymix\Framework\Config::set('debug.display_content', $debug_content);
// Log filename
diff --git a/modules/admin/admin.admin.view.php b/modules/admin/admin.admin.view.php
index eb9db8ce9..7837eb535 100644
--- a/modules/admin/admin.admin.view.php
+++ b/modules/admin/admin.admin.view.php
@@ -325,8 +325,11 @@ class adminAdminView extends admin
}
// Get need update from easy install
- $oAutoinstallAdminModel = getAdminModel('autoinstall');
- $needUpdateList = $oAutoinstallAdminModel->getNeedUpdateList();
+ //$oAutoinstallAdminModel = getAdminModel('autoinstall');
+ //$needUpdateList = $oAutoinstallAdminModel->getNeedUpdateList();
+ $needUpdateList = array();
+
+ // Check counter addon
$site_module_info = Context::get('site_module_info');
$oAddonAdminModel = getAdminModel('addon');
$counterAddonActivated = $oAddonAdminModel->isActivatedAddon('counter', $site_module_info->site_srl );
diff --git a/modules/admin/tpl/config_debug.html b/modules/admin/tpl/config_debug.html
index f292961d5..12b5d3c1e 100644
--- a/modules/admin/tpl/config_debug.html
+++ b/modules/admin/tpl/config_debug.html
@@ -56,14 +56,14 @@
diff --git a/modules/admin/tpl/js/admin.js b/modules/admin/tpl/js/admin.js
index 271633d8b..13a2e67f6 100644
--- a/modules/admin/tpl/js/admin.js
+++ b/modules/admin/tpl/js/admin.js
@@ -1425,6 +1425,7 @@ jQuery(function($){
// Details toggle in admin table
var simpleBtn = $('.x .dsTg .__simple');
var detailBtn = $('.x .dsTg .__detail');
+ var tableContainer = $('.x .dsTg');
var tdTitle = $('.x .dsTg td.title');
tdTitle.each(function(){
var $t = $(this);
@@ -1439,12 +1440,14 @@ jQuery(function($){
simples.show();
detailBtn.removeClass('x_active');
simpleBtn.addClass('x_active');
+ tableContainer.addClass('__simpleView');
};
var detailBtnFn = function(){
details.show();
simples.hide();
detailBtn.addClass('x_active');
simpleBtn.removeClass('x_active');
+ tableContainer.removeClass('__simpleView');
};
simpleBtn.click(simpleBtnFn);
detailBtn.click(detailBtnFn);
diff --git a/modules/autoinstall/autoinstall.admin.controller.php b/modules/autoinstall/autoinstall.admin.controller.php
index f6f195f79..5eabf8244 100644
--- a/modules/autoinstall/autoinstall.admin.controller.php
+++ b/modules/autoinstall/autoinstall.admin.controller.php
@@ -201,6 +201,12 @@ class autoinstallAdminController extends autoinstall
foreach($packages as $package_srl)
{
$package = $oModel->getPackage($package_srl);
+ $package->type = $oModel->getTypeFromPath($package->path);
+ if ($package->type === 'core')
+ {
+ continue;
+ }
+
if($oAdminModel->checkUseDirectModuleInstall($package)->toBool())
{
$oModuleInstaller = new DirectModuleInstaller($package);
diff --git a/modules/autoinstall/autoinstall.admin.model.php b/modules/autoinstall/autoinstall.admin.model.php
index fad936108..db5d0abeb 100644
--- a/modules/autoinstall/autoinstall.admin.model.php
+++ b/modules/autoinstall/autoinstall.admin.model.php
@@ -215,7 +215,6 @@ class autoinstallAdminModel extends autoinstall
if($packageInfo->type == 'core')
{
- //$title = 'XpressEngine';
continue;
}
else
diff --git a/modules/autoinstall/autoinstall.admin.view.php b/modules/autoinstall/autoinstall.admin.view.php
index 0f9cb7ec4..446dbd5e1 100644
--- a/modules/autoinstall/autoinstall.admin.view.php
+++ b/modules/autoinstall/autoinstall.admin.view.php
@@ -216,7 +216,7 @@ class autoinstallAdminView extends autoinstall
if($v->type == "core")
{
- $v->avail_remove = FALSE;
+ continue;
}
else if($v->type == "module")
{
diff --git a/modules/autoinstall/tpl/category.html b/modules/autoinstall/tpl/category.html
index d1cb9b7b5..288b7c56f 100644
--- a/modules/autoinstall/tpl/category.html
+++ b/modules/autoinstall/tpl/category.html
@@ -7,7 +7,7 @@
{$category->title}
diff --git a/modules/autoinstall/tpl/install.html b/modules/autoinstall/tpl/install.html
index 7c0e505cf..55e2e4642 100644
--- a/modules/autoinstall/tpl/install.html
+++ b/modules/autoinstall/tpl/install.html
@@ -17,10 +17,6 @@
-
-
{$lang->msg_update_core_title}
-
{$lang->msg_update_core}
-
{$lang->current_version}: {$package->cur_version} ({$lang->require_update})
diff --git a/modules/comment/comment.controller.php b/modules/comment/comment.controller.php
index aa124faad..1d6e8d948 100644
--- a/modules/comment/comment.controller.php
+++ b/modules/comment/comment.controller.php
@@ -720,7 +720,10 @@ class commentController extends comment
$oMail->setSubject($mail_title);
$oMail->setBody($mail_content);
$oMail->setFrom(config('mail.default_from') ?: $member_info->email_address, $member_info->nick_name);
- $oMail->setReplyTo($member_info->email_address);
+ if($member_info->email_address)
+ {
+ $oMail->setReplyTo($member_info->email_address);
+ }
foreach (array_map('trim', explode(',', $module_info->admin_mail)) as $email_address)
{
if ($email_address && $email_address !== $author_email_address)
diff --git a/modules/file/file.admin.controller.php b/modules/file/file.admin.controller.php
index 955019225..417163e06 100644
--- a/modules/file/file.admin.controller.php
+++ b/modules/file/file.admin.controller.php
@@ -77,8 +77,16 @@ class fileAdminController extends file
$config->image_remove_exif_data = Context::get('image_remove_exif_data') === 'Y' ? true : false;
$config->video_thumbnail = Context::get('video_thumbnail') === 'Y' ? true : false;
$config->video_mp4_gif_time = intval(Context::get('video_mp4_gif_time'));
- $config->ffmpeg_command = escape(utf8_trim(Context::get('ffmpeg_command'))) ?: '/usr/bin/ffmpeg';
- $config->ffprobe_command = escape(utf8_trim(Context::get('ffprobe_command'))) ?: '/usr/bin/ffprobe';
+ if (RX_WINDOWS)
+ {
+ $config->ffmpeg_command = escape(Context::get('ffmpeg_command')) ?: 'C:\Program Files\ffmpeg\bin\ffmpeg.exe';
+ $config->ffprobe_command = escape(Context::get('ffprobe_command')) ?: 'C:\Program Files\ffmpeg\bin\ffprobe.exe';
+ }
+ else
+ {
+ $config->ffmpeg_command = escape(utf8_trim(Context::get('ffmpeg_command'))) ?: '/usr/bin/ffmpeg';
+ $config->ffprobe_command = escape(utf8_trim(Context::get('ffprobe_command'))) ?: '/usr/bin/ffprobe';
+ }
// Check maximum file size
if (PHP_INT_SIZE < 8)
diff --git a/modules/file/file.controller.php b/modules/file/file.controller.php
index 659fdf7b6..650be2778 100644
--- a/modules/file/file.controller.php
+++ b/modules/file/file.controller.php
@@ -1178,8 +1178,15 @@ class fileController extends file
$adjusted['height'] -= $adjusted['height'] % 2;
// Convert using ffmpeg
- $command = $config->ffmpeg_command;
- $command .= ' -i ' . escapeshellarg($file_info['tmp_name']);
+ if (RX_WINDOWS)
+ {
+ $command = escapeshellarg($config->ffmpeg_command);
+ }
+ else
+ {
+ $command = $config->ffmpeg_command;
+ }
+ $command .= ' -nostdin -i ' . escapeshellarg($file_info['tmp_name']);
$command .= ' -movflags +faststart -pix_fmt yuv420p -c:v libx264 -crf 23';
$command .= sprintf(' -vf "scale=%d:%d"', $adjusted['width'], $adjusted['height']);
$command .= ' ' . escapeshellarg($output_name);
diff --git a/modules/message/m.skins/default/system_message.html b/modules/message/m.skins/default/system_message.html
index ab3c8e3c2..5ac43b9b6 100644
--- a/modules/message/m.skins/default/system_message.html
+++ b/modules/message/m.skins/default/system_message.html
@@ -3,6 +3,9 @@
{$system_message}
+
+ {$system_message_detail}
+
@@ -62,4 +65,4 @@ jQuery(function($){
}
});
});
-
\ No newline at end of file
+
diff --git a/modules/module/module.model.php b/modules/module/module.model.php
index f161f87c3..3cce26750 100644
--- a/modules/module/module.model.php
+++ b/modules/module/module.model.php
@@ -736,6 +736,7 @@ class moduleModel extends module
$module_info->homepage = $xml_obj->link->body;
$module_info->category = $xml_obj->category->body;
if(!$module_info->category) $module_info->category = 'service';
+ $date_obj = (object)array('y' => 0, 'm' => 0, 'd' => 0);
sscanf($xml_obj->date->body, '%d-%d-%d', $date_obj->y, $date_obj->m, $date_obj->d);
$module_info->date = sprintf('%04d%02d%02d', $date_obj->y, $date_obj->m, $date_obj->d);
$module_info->license = $xml_obj->license->body;
@@ -761,6 +762,7 @@ class moduleModel extends module
$module_info->version = $xml_obj->attrs->version;
$module_info->category = $xml_obj->attrs->category;
if(!$module_info->category) $module_info->category = 'service';
+ $date_obj = (object)array('y' => 0, 'm' => 0, 'd' => 0);
sscanf($xml_obj->author->attrs->date, '%d. %d. %d', $date_obj->y, $date_obj->m, $date_obj->d);
$module_info->date = sprintf('%04d%02d%02d', $date_obj->y, $date_obj->m, $date_obj->d);
$author_obj = new stdClass();
diff --git a/modules/module/tpl/css/module_admin.less b/modules/module/tpl/css/module_admin.less
index bdc325761..d1e9fb9d5 100644
--- a/modules/module/tpl/css/module_admin.less
+++ b/modules/module/tpl/css/module_admin.less
@@ -13,6 +13,9 @@
top: -1px;
}
}
+.__simpleView .fvOff,.__simpleView .fvOn{
+ top:0;
+}
.fvOff{
background-image: data-uri('images/star-empty.svg');
}
diff --git a/modules/page/page.admin.controller.php b/modules/page/page.admin.controller.php
index 87520d8fb..0750b58e8 100644
--- a/modules/page/page.admin.controller.php
+++ b/modules/page/page.admin.controller.php
@@ -319,7 +319,7 @@ class pageAdminController extends page
$oDocument = $oDocumentModel->getDocument($obj->document_srl);
$bAnonymous = false;
- $target = ($obj->ismobile == 'Y') ? 'mdocument_srl' : 'document_srl';
+ $target = ($obj->isMobile == 'Y') ? 'mdocument_srl' : 'document_srl';
// 이미 존재하는 경우 수정
if($oDocument->isExists() && $oDocument->document_srl == $obj->document_srl)
@@ -348,7 +348,7 @@ class pageAdminController extends page
// 결과를 리턴
$this->add('mid', Context::get('mid'));
$this->add('document_srl', $output->get('document_srl'));
- $this->add('is_mobile', $obj->ismobile);
+ $this->add('is_mobile', $obj->isMobile);
// 성공 메세지 등록
$this->setMessage($msg_code);