Project

General

Profile

« Previous | Next » 

Revision 2077

Added by darkviper almost 11 years ago

  1. little fixes in modules/news
  2. little fixes in some other files

View differences:

UpgradeHelper.php
129 129
	{
130 130
		if (defined('DB_PASSWORD')) {
131 131
		// old config.php is active
132
			if (!is_writable($sAppPath.'config.php') || !is_writable($sAppPath.'config.php.new') || !is_writable($sAppPath.'setup.ini.php.new'))
132
			if (    !is_writable($sAppPath.'config.php')
133
                 || (file_exists($sAppPath.'config.php.new') && !is_writable($sAppPath.'config.php.new'))
134
                 || (file_exists($sAppPath.'setup.ini.php') && !is_writable($sAppPath.'setup.ini.php'))
135
                 || (!file_exists($sAppPath.'setup.ini.php') && !is_writable($sAppPath.'setup.ini.php.new'))
136
               )
133 137
			{
134 138
			// stop script if there's an error occured
135
				$sMsg = 'Following files must exist and be writable to run upgrade:<br />'
136
				      . '<ul><li>config.php</li>'.(file_exists($sAppPath.'config.php.new') ? '<li>config.php.new</li>' : '')
137
				      . '<li>setup.ini.php.new</li></ul>';
139
				$sMsg = 'Following files must exist and be writable to run upgrade:<br />'.PHP_EOL
140
				      . '<ul>'.PHP_EOL
141
                      . '<li>config.php</li>'.PHP_EOL
142
                      . (file_exists($sAppPath.'config.php.new') ? '<li>config.php.new</li>'.PHP_EOL : '')
143
                      . (file_exists($sAppPath.'setup.ini.php') ? '<li>setup.ini.php</li>'.PHP_EOL : '')
144
                      . (!file_exists($sAppPath.'setup.ini.php') ? '<li>setup.ini.php.new</li>'.PHP_EOL : '')
145
                      . '</ul>'.PHP_EOL;
138 146
				self::dieWithMessage($sMsg);
139 147
			} else { // ok, let's change the files now!
140 148
				if (file_exists($sAppPath.'setup.ini.php')) {

Also available in: Unified diff