Skip to content

Commit 9f085ac

Browse files
author
bnu
committed
Merge branch 'release/1.8.8'
2 parents f2f82cd + 5c6501c commit 9f085ac

13 files changed

+55
-43
lines changed

.travis.yml

+1
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ matrix:
1010
allow_failures:
1111
- php: 7
1212
- php: hhvm
13+
sudo: false
1314
before_script:
1415
- travis_retry composer self-update
1516
- npm install -g grunt-cli

classes/context/Context.class.php

+1
Original file line numberDiff line numberDiff line change
@@ -1658,6 +1658,7 @@ function getUrl($num_args = 0, $args_list = array(), $domain = null, $encode = T
16581658
'document_srl.mid' => "$mid/$srl",
16591659
'document_srl.vid' => "$vid/$srl",
16601660
'document_srl.mid.vid' => "$vid/$mid/$srl",
1661+
'act' => ($is_feed && $act !== 'api') ? $act : '',
16611662
'act.mid' => $is_feed ? "$mid/$act" : '',
16621663
'act.mid.vid' => $is_feed ? "$vid/$mid/$act" : '',
16631664
'act.document_srl.key' => ($act == 'trackback') ? "$srl/$key/$act" : '',

config/config.inc.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
/**
3030
* Display XE's full version.
3131
*/
32-
define('__XE_VERSION__', '1.8.7');
32+
define('__XE_VERSION__', '1.8.8');
3333
define('__XE_VERSION_ALPHA__', (stripos(__XE_VERSION__, 'alpha') !== false));
3434
define('__XE_VERSION_BETA__', (stripos(__XE_VERSION__, 'beta') !== false));
3535
define('__XE_VERSION_RC__', (stripos(__XE_VERSION__, 'rc') !== false));

modules/file/file.controller.php

+6-5
Original file line numberDiff line numberDiff line change
@@ -662,16 +662,17 @@ function insertFile($file_info, $module_srl, $upload_target_srl, $download_count
662662
}
663663
}
664664

665+
// https://github.com/xpressengine/xe-core/issues/1713
666+
$file_info['name'] = preg_replace('/\.(php|phtm|phar|html?|cgi|pl|exe|jsp|asp|inc)/i', '$0-x',$file_info['name']);
667+
$file_info['name'] = removeHackTag($file_info['name']);
668+
$file_info['name'] = str_replace(array('<','>'),array('%3C','%3E'),$file_info['name']);
669+
665670
// Get random number generator
666671
$random = new Password();
667-
672+
668673
// Set upload path by checking if the attachement is an image or other kinds of file
669674
if(preg_match("/\.(jpe?g|gif|png|wm[va]|mpe?g|avi|swf|flv|mp[1-4]|as[fx]|wav|midi?|moo?v|qt|r[am]{1,2}|m4v)$/i", $file_info['name']))
670675
{
671-
// Immediately remove the direct file if it has any kind of extensions for hacking
672-
$file_info['name'] = preg_replace('/\.(php|phtm|phar|html?|cgi|pl|exe|jsp|asp|inc)/i', '$0-x',$file_info['name']);
673-
$file_info['name'] = str_replace(array('<','>'),array('%3C','%3E'),$file_info['name']);
674-
675676
$path = sprintf("./files/attach/images/%s/%s", $module_srl,getNumberingPath($upload_target_srl,3));
676677

677678
// special character to '_'

modules/file/file.model.php

+1
Original file line numberDiff line numberDiff line change
@@ -220,6 +220,7 @@ function getFiles($upload_target_srl, $columnList = array(), $sortIndex = 'file_
220220
{
221221
$file = $file_list[$i];
222222
$file->source_filename = stripslashes($file->source_filename);
223+
$file->source_filename = htmlspecialchars($file->source_filename);
223224
$file->download_url = $this->getDownloadUrl($file->file_srl, $file->sid, $file->module_srl);
224225
$file_list[$i] = $file;
225226
}

modules/install/lang/lang.xml

+16-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<value xml:lang="en"><![CDATA[XE Installation]]></value>
66
<value xml:lang="jp"><![CDATA[XEのインストール]]></value>
77
<value xml:lang="zh-CN"><![CDATA[安装XE]]></value>
8-
<value xml:lang="zh-TW"><![CDATA[XE程式安裝]]></value>
8+
<value xml:lang="zh-TW"><![CDATA[安裝XE]]></value>
99
<value xml:lang="fr"><![CDATA[Installation du XE ]]></value>
1010
<value xml:lang="ru"><![CDATA[Установка XE]]></value>
1111
<value xml:lang="es"><![CDATA[Instalación de XE ]]></value>
@@ -34,36 +34,51 @@
3434
<item name="license_agreement">
3535
<value xml:lang="ko"><![CDATA[사용권 동의]]></value>
3636
<value xml:lang="en"><![CDATA[License agreement]]></value>
37+
<value xml:lang="jp"><![CDATA[ライセンス契約]]></value>
38+
<value xml:lang="zh-CN"><![CDATA[许可协议]]></value>
39+
<value xml:lang="zh-TW"><![CDATA[許可協議]]></value>
3740
</item>
3841
<item name="condition">
3942
<value xml:lang="ko"><![CDATA[설치 조건 확인]]></value>
4043
<value xml:lang="en"><![CDATA[Check the installation conditions]]></value>
4144
<value xml:lang="jp"><![CDATA[インストール条件確認]]></value>
45+
<value xml:lang="zh-CN"><![CDATA[检查安装条件]]></value>
46+
<value xml:lang="zh-TW"><![CDATA[檢查安裝條件]]></value>
4247
</item>
4348
<item name="ftp">
4449
<value xml:lang="ko"><![CDATA[FTP 정보 입력]]></value>
4550
<value xml:lang="en"><![CDATA[Input FTP information]]></value>
4651
<value xml:lang="jp"><![CDATA[FTP情報入力]]></value>
52+
<value xml:lang="zh-CN"><![CDATA[输入FTP信息]]></value>
53+
<value xml:lang="zh-TW"><![CDATA[輸入FTP信息]]></value>
4754
</item>
4855
<item name="dbSelect">
4956
<value xml:lang="ko"><![CDATA[DB 선택]]></value>
5057
<value xml:lang="en"><![CDATA[Choose database type]]></value>
5158
<value xml:lang="jp"><![CDATA[DB選択]]></value>
59+
<value xml:lang="zh-CN"><![CDATA[选择DB]]></value>
60+
<value xml:lang="zh-TW"><![CDATA[選擇DB]]></value>
5261
</item>
5362
<item name="dbInfo">
5463
<value xml:lang="ko"><![CDATA[DB 정보 입력]]></value>
5564
<value xml:lang="en"><![CDATA[Input Database information]]></value>
5665
<value xml:lang="jp"><![CDATA[DB情報入力]]></value>
66+
<value xml:lang="zh-CN"><![CDATA[输入DB信息]]></value>
67+
<value xml:lang="zh-TW"><![CDATA[輸入DB信息]]></value>
5768
</item>
5869
<item name="configInfo">
5970
<value xml:lang="ko"><![CDATA[환경 설정]]></value>
6071
<value xml:lang="en"><![CDATA[Settings]]></value>
6172
<value xml:lang="jp"><![CDATA[環境設定]]></value>
73+
<value xml:lang="zh-CN"><![CDATA[环境设置]]></value>
74+
<value xml:lang="zh-TW"><![CDATA[環境設置]]></value>
6275
</item>
6376
<item name="adminInfo">
6477
<value xml:lang="ko"><![CDATA[관리자 정보 입력]]></value>
6578
<value xml:lang="en"><![CDATA[Enter Administrator information]]></value>
6679
<value xml:lang="jp"><![CDATA[管理者情報入力]]></value>
80+
<value xml:lang="zh-CN"><![CDATA[输入管理员信息]]></value>
81+
<value xml:lang="zh-TW"><![CDATA[輸入管理員信息]]></value>
6782
</item>
6883
</item>
6984
<item name="install_condition_enable">

modules/rss/rss.admin.view.php

+1
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ function dispRssAdminIndex()
5555
}
5656
}
5757
if(!$total_config->feed_document_count) $total_config->feed_document_count = 15;
58+
$total_config->url = $oRssModel->getModuleFeedUrl(NULL, '', 'rss', true);
5859

5960
Context::set('feed_config', $feed_config);
6061
Context::set('total_config', $total_config);

modules/rss/rss.model.php

+6-14
Original file line numberDiff line numberDiff line change
@@ -12,27 +12,19 @@ class rssModel extends rss
1212
*
1313
* @param string $vid Vid
1414
* @param string $mid mid
15-
* @param string $format Feed format. ef)xe, atom, rss1.0
15+
* @param string $format Feed format. rss | atom
16+
* @param bool $absolute_url
1617
* @return string
1718
*/
18-
function getModuleFeedUrl($vid = null, $mid, $format)
19+
function getModuleFeedUrl($vid, $mid, $format = 'rss', $absolute_url = false)
1920
{
20-
if(Context::isAllowRewrite())
21+
if($absolute_url)
2122
{
22-
$request_uri = Context::getRequestUri();
23-
// If the virtual site variable exists and it is different from mid (vid and mid should not be the same)
24-
if($vid && $vid != $mid)
25-
{
26-
return $request_uri.$vid.'/'.$mid.'/'.$format;
27-
}
28-
else
29-
{
30-
return $request_uri.$mid.'/'.$format;
31-
}
23+
return getFullUrl('','vid',$vid, 'mid',$mid, 'act',$format);
3224
}
3325
else
3426
{
35-
return getUrl('','mid',$mid,'act',$format);
27+
return getUrl('','vid',$vid, 'mid',$mid, 'act',$format);
3628
}
3729
}
3830

modules/rss/rss.view.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,7 @@ function rss($document_list = null, $rss_title = null, $add_description = null)
172172
$info->id = $proctcl.$_SERVER['HTTP_HOST'].$info->id;
173173
}
174174

175-
$info->language = Context::getLangType();
175+
$info->language = str_replace('jp','ja',Context::getLangType());
176176
// Set the variables used in the RSS output
177177
Context::set('info', $info);
178178
Context::set('feed_config', $config);

modules/rss/ruleset/insertRssConfig.xml

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
1-
<?xml version="1.0" encoding="utf-8"?>
1+
<?xml version="1.0" encoding="UTF-8"?>
22
<ruleset version="1.5.0">
3-
<customrules>
3+
<customrules>
44
<rule name="boolean" type="enum" test="Y,N" />
5-
</customrules>
6-
<fields>
5+
</customrules>
6+
<fields>
77
<field name="module" required="true" default="rss" />
88
<field name="act" required="true" default="procRssAdminInsertConfig" />
99
<field name="use_total_feed" required="true" default="Y" rule="boolean" />
10-
<field name="feed_title" required="true">
10+
<field name="feed_title">
1111
<title xml:lang="ko">피드(Feed) 제목</title>
1212
<title xml:lang="en">Feed Title</title>
1313
</field>

modules/rss/tpl/rss_admin_index.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ <h1>{$lang->total_feed} {$lang->cmd_management}</h1>
1212
<input type="hidden" name="xe_validator_id" value="modules/rss/tpl/rss_admin_index/1" />
1313
<div class="x_control-group">
1414
<div class="x_control-label">{$lang->url}</div>
15-
<div class="x_controls" style="padding-top:5px"><a href="{getFullSiteUrl()}rss" target="_blank">{getFullSiteUrl()}rss</a></div>
15+
<div class="x_controls" style="padding-top:5px"><a href="{$total_config->url}" target="_blank">{$total_config->url}</a></div>
1616
</div>
1717
<div class="x_control-group">
1818
<label class="x_control-label">{$lang->total_feed}</label>

tests/Install/InstallTester.php

+10-10
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php //[STAMP] 655f3852f47c53f31093f448f1b7f2c5
1+
<?php //[STAMP] 8226438e4d1a01d3ebb358f3af77c814
22

33
// This class was automatically generated by build task
44
// You should not change it manually as it will be overwritten on next build
@@ -1639,7 +1639,7 @@ public function setCookie($name, $val, $params = null) {
16391639
* @return mixed
16401640
* @see \Codeception\Lib\InnerBrowser::grabCookie()
16411641
*/
1642-
public function grabCookie($name, $params = null) {
1642+
public function grabCookie($cookie, $params = null) {
16431643
return $this->scenario->runStep(new \Codeception\Step\Action('grabCookie', func_get_args()));
16441644
}
16451645

@@ -1662,7 +1662,7 @@ public function grabCookie($name, $params = null) {
16621662
* Conditional Assertion: Test won't be stopped on fail
16631663
* @see \Codeception\Lib\InnerBrowser::seeCookie()
16641664
*/
1665-
public function canSeeCookie($name, $params = null) {
1665+
public function canSeeCookie($cookie, $params = null) {
16661666
return $this->scenario->runStep(new \Codeception\Step\ConditionalAssertion('seeCookie', func_get_args()));
16671667
}
16681668
/**
@@ -1682,7 +1682,7 @@ public function canSeeCookie($name, $params = null) {
16821682
* @return mixed
16831683
* @see \Codeception\Lib\InnerBrowser::seeCookie()
16841684
*/
1685-
public function seeCookie($name, $params = null) {
1685+
public function seeCookie($cookie, $params = null) {
16861686
return $this->scenario->runStep(new \Codeception\Step\Assertion('seeCookie', func_get_args()));
16871687
}
16881688

@@ -1700,7 +1700,7 @@ public function seeCookie($name, $params = null) {
17001700
* Conditional Assertion: Test won't be stopped on fail
17011701
* @see \Codeception\Lib\InnerBrowser::dontSeeCookie()
17021702
*/
1703-
public function cantSeeCookie($name, $params = null) {
1703+
public function cantSeeCookie($cookie, $params = null) {
17041704
return $this->scenario->runStep(new \Codeception\Step\ConditionalAssertion('dontSeeCookie', func_get_args()));
17051705
}
17061706
/**
@@ -1715,7 +1715,7 @@ public function cantSeeCookie($name, $params = null) {
17151715
* @return mixed
17161716
* @see \Codeception\Lib\InnerBrowser::dontSeeCookie()
17171717
*/
1718-
public function dontSeeCookie($name, $params = null) {
1718+
public function dontSeeCookie($cookie, $params = null) {
17191719
return $this->scenario->runStep(new \Codeception\Step\Assertion('dontSeeCookie', func_get_args()));
17201720
}
17211721

@@ -1900,7 +1900,7 @@ public function seeNumberOfElements($selector, $expected) {
19001900
* Conditional Assertion: Test won't be stopped on fail
19011901
* @see \Codeception\Lib\InnerBrowser::seeOptionIsSelected()
19021902
*/
1903-
public function canSeeOptionIsSelected($select, $optionText) {
1903+
public function canSeeOptionIsSelected($selector, $optionText) {
19041904
return $this->scenario->runStep(new \Codeception\Step\ConditionalAssertion('seeOptionIsSelected', func_get_args()));
19051905
}
19061906
/**
@@ -1920,7 +1920,7 @@ public function canSeeOptionIsSelected($select, $optionText) {
19201920
* @return mixed
19211921
* @see \Codeception\Lib\InnerBrowser::seeOptionIsSelected()
19221922
*/
1923-
public function seeOptionIsSelected($select, $optionText) {
1923+
public function seeOptionIsSelected($selector, $optionText) {
19241924
return $this->scenario->runStep(new \Codeception\Step\Assertion('seeOptionIsSelected', func_get_args()));
19251925
}
19261926

@@ -1943,7 +1943,7 @@ public function seeOptionIsSelected($select, $optionText) {
19431943
* Conditional Assertion: Test won't be stopped on fail
19441944
* @see \Codeception\Lib\InnerBrowser::dontSeeOptionIsSelected()
19451945
*/
1946-
public function cantSeeOptionIsSelected($select, $optionText) {
1946+
public function cantSeeOptionIsSelected($selector, $optionText) {
19471947
return $this->scenario->runStep(new \Codeception\Step\ConditionalAssertion('dontSeeOptionIsSelected', func_get_args()));
19481948
}
19491949
/**
@@ -1963,7 +1963,7 @@ public function cantSeeOptionIsSelected($select, $optionText) {
19631963
* @return mixed
19641964
* @see \Codeception\Lib\InnerBrowser::dontSeeOptionIsSelected()
19651965
*/
1966-
public function dontSeeOptionIsSelected($select, $optionText) {
1966+
public function dontSeeOptionIsSelected($selector, $optionText) {
19671967
return $this->scenario->runStep(new \Codeception\Step\Assertion('dontSeeOptionIsSelected', func_get_args()));
19681968
}
19691969

tests/unit/UnitTester.php

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php //[STAMP] bd6b55949e6a72559e6ee503e29432bb
1+
<?php //[STAMP] 3dec2fc1382a9643e3c2a5f6e95c8413
22

33
// This class was automatically generated by build task
44
// You should not change it manually as it will be overwritten on next build
@@ -93,7 +93,7 @@ public function assertNotSame($expected, $actual, $message = null) {
9393
/**
9494
* [!] Method is generated. Documentation taken from corresponding module.
9595
*
96-
* Checks that expected is greater than actual
96+
* Checks that actual is greater than expected
9797
*
9898
* @param $expected
9999
* @param $actual
@@ -119,7 +119,7 @@ public function assertGreaterThen($expected, $actual, $message = null) {
119119
/**
120120
* [!] Method is generated. Documentation taken from corresponding module.
121121
*
122-
* Checks that expected is greater or equal than actual
122+
* Checks that actual is greater or equal than expected
123123
*
124124
* @param $expected
125125
* @param $actual
@@ -145,7 +145,7 @@ public function assertGreaterThenOrEqual($expected, $actual, $message = null) {
145145
/**
146146
* [!] Method is generated. Documentation taken from corresponding module.
147147
*
148-
* Checks that expected is less than actual
148+
* Checks that actual is less than expected
149149
*
150150
* @param $expected
151151
* @param $actual
@@ -160,7 +160,7 @@ public function assertLessThan($expected, $actual, $message = null) {
160160
/**
161161
* [!] Method is generated. Documentation taken from corresponding module.
162162
*
163-
* Checks that expected is less or equal than actual
163+
* Checks that actual is less or equal than expected
164164
*
165165
* @param $expected
166166
* @param $actual

0 commit comments

Comments
 (0)