Project

General

Profile

« Previous | Next » 

Revision 2084

Added by darkviper almost 11 years ago

  1. modules/wysiwyg/upgrade copy-past mistake corrected

View differences:

branches/2.8.x/CHANGELOG
11 11
! = Update/Change
12 12
===============================================================================
13 13

  
14
16 Jan-2014 Build 2084 Manuela v.d.Decken(DarkViper)
15
# modules/wysiwyg/upgrade copy-past mistake corrected
14 16
15 Jan-2014 Build 2083 Manuela v.d.Decken(DarkViper)
15 17
# modules/news/upgrade manipulation of {SYSVAR:}-Tags fixed
16 18
# modules/wysiwyg/upgrade manipulation of {SYSVAR:}-Tags fixed
branches/2.8.x/wb/admin/interface/version.php
51 51

  
52 52
// check if defined to avoid errors during installation (redirect to admin panel fails if PHP error/warnings are enabled)
53 53
if(!defined('VERSION')) define('VERSION', '2.8.4');
54
if(!defined('REVISION')) define('REVISION', '2083');
54
if(!defined('REVISION')) define('REVISION', '2084');
55 55
if(!defined('SP')) define('SP', '');
branches/2.8.x/wb/modules/wysiwyg/upgrade.php
101 101
                $aReplace = array( '{SYSVAR:AppUrl.MediaDir}', '{SYSVAR:AppUrl}', '{SYSVAR:AppUrl.MediaDir}', '{SYSVAR:AppUrl}', '\1', '\1');
102 102
                while (($aEntry = $oEntrySet->fetchRow(MYSQL_ASSOC))) {
103 103
                    $iCount = 0;
104
                    $aSubject = array($aEntry['content_long'], $aEntry['content_short']);
105
                    $aNewContents = preg_replace($aSearch, $aReplace, $aSubject, -1, $iCount);
104
                    $aEntry['content'] = preg_replace($aSearch, $aReplace, $aEntry['content'], -1, $iCount);
106 105
                    if ($iCount > 0) {
107 106
                        $iReplaced += $iCount;
108
                        $sql = 'UPDATE `'.$oDb->TablePrefix.'mod_news_posts` '
109
                             . 'SET `content_long`=\''.$oDb->escapeString($aNewContents[0]).'\', '
110
                             .     '`content_short`=\''.$oDb->escapeString($aNewContents[1]).'\' '
111
                             . 'WHERE `post_id`='.$aEntry['post_id'];
107
                        $sql = 'UPDATE `'.$oDb->TablePrefix.'mod_wysiwyg` '
108
                             . 'SET `content`=\''.$oDb->escapeString($aEntry['content']).'\' '
109
                             . 'WHERE `section_id`='.$aEntry['section_id'];
112 110
                        $oDb->doQuery($sql);
113 111
                        $iRecords++;
114 112
                    }

Also available in: Unified diff