Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fixed issue #9822: Unable to upload image on server via KCFinder
  • Loading branch information
c-schmitz committed Aug 21, 2015
1 parent 9424e01 commit d27535c
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion application/config/version.php
Expand Up @@ -13,7 +13,7 @@
*/

$config['versionnumber'] = "2.06+";
$config['dbversionnumber'] = 183;
$config['dbversionnumber'] = 184;
$config['buildnumber'] = '';
$config['updatable'] = true;

Expand Down
16 changes: 8 additions & 8 deletions application/helpers/update/updatedb_helper.php
Expand Up @@ -1307,16 +1307,16 @@ function db_upgrade_all($iOldDBVersion) {
upgradeSurveyTables181();
$oDB->createCommand()->update('{{settings_global}}',array('stg_value'=>181),"stg_name='DBVersion'");
}
if ($iOldDBVersion < 182)
{
fixKCFinder182();
$oDB->createCommand()->update('{{settings_global}}',array('stg_value'=>182),"stg_name='DBVersion'");
}
if ($iOldDBVersion < 183)
{
upgradeSurveyTables183();
$oDB->createCommand()->update('{{settings_global}}',array('stg_value'=>183),"stg_name='DBVersion'");
}
if ($iOldDBVersion < 184)
{
fixKCFinder184();
$oDB->createCommand()->update('{{settings_global}}',array('stg_value'=>184),"stg_name='DBVersion'");
}
$oTransaction->commit();
// Activate schema caching
$oDB->schemaCachingDuration=3600;
Expand Down Expand Up @@ -1361,15 +1361,15 @@ function upgradeSurveyTables183()
}


function fixKCFinder182()
function fixKCFinder184()
{
$sThirdPartyDir=Yii::app()->getConfig('standardtemplaterootdir').DIRECTORY_SEPARATOR.'third_party'.DIRECTORY_SEPARATOR;
$sThirdPartyDir=Yii::app()->getConfig('homedir').DIRECTORY_SEPARATOR.'third_party'.DIRECTORY_SEPARATOR;
rmdirr($sThirdPartyDir.'ckeditor/plugins/toolbar');
rmdirr($sThirdPartyDir.'ckeditor/plugins/toolbar/ls-office2003');
array_map('unlink', glob($sThirdPartyDir.'kcfinder/cache/*.js'));
array_map('unlink', glob($sThirdPartyDir.'kcfinder/cache/*.css'));
rmdirr($sThirdPartyDir.'kcfinder/upload/files');
rmdirr($sThirdPartyDir.'kcfinder/upload/.htumbs');
rmdirr($sThirdPartyDir.'kcfinder/upload/.thumbs');
}


Expand Down
2 changes: 1 addition & 1 deletion installer/sql/create-mssql.sql
Expand Up @@ -566,4 +566,4 @@ create index [parent_qid_idx] on [prefix_questions] ([parent_qid]);
--
-- Version Info
--
INSERT INTO [prefix_settings_global] VALUES ('DBVersion', '183');
INSERT INTO [prefix_settings_global] VALUES ('DBVersion', '184');
2 changes: 1 addition & 1 deletion installer/sql/create-mysql.sql
Expand Up @@ -575,4 +575,4 @@ CREATE INDEX `parent_qid_idx` ON `prefix_questions` (`parent_qid`);
--
-- Version Info
--
INSERT INTO `prefix_settings_global` VALUES ('DBVersion', '183');
INSERT INTO `prefix_settings_global` VALUES ('DBVersion', '184');
2 changes: 1 addition & 1 deletion installer/sql/create-pgsql.sql
Expand Up @@ -576,4 +576,4 @@ create unique index permissions_idx2 ON prefix_permissions (entity_id, entity, u
--
-- Version Info
--
INSERT INTO prefix_settings_global VALUES ('DBVersion', '183');
INSERT INTO prefix_settings_global VALUES ('DBVersion', '184');

0 comments on commit d27535c

Please sign in to comment.