mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-27 21:58:52 +00:00
- empty() expects a variable, not a function :D
git-svn-id: file:///svn/phpbb/trunk@5625 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
d85c4e73ed
commit
148f259bde
2 changed files with 8 additions and 4 deletions
|
@ -1120,7 +1120,9 @@ class acp_attachments
|
|||
|
||||
$exe = ((defined('PHP_OS')) && (preg_match('#win#i', PHP_OS))) ? '.exe' : '';
|
||||
|
||||
if (empty(getenv('MAGICK_HOME')))
|
||||
$magic_home = getenv('MAGICK_HOME');
|
||||
|
||||
if (empty($magic_home))
|
||||
{
|
||||
$locations = array('C:/WINDOWS/', 'C:/WINNT/', 'C:/WINDOWS/SYSTEM/', 'C:/WINNT/SYSTEM/', 'C:/WINDOWS/SYSTEM32/', 'C:/WINNT/SYSTEM32/', '/usr/bin/', '/usr/sbin/', '/usr/local/bin/', '/usr/local/sbin/', '/opt/', '/usr/imagemagick/', '/usr/bin/imagemagick/');
|
||||
$path_locations = str_replace('\\', '/', (explode(($exe) ? ';' : ':', getenv('PATH'))));
|
||||
|
@ -1144,7 +1146,7 @@ class acp_attachments
|
|||
}
|
||||
else
|
||||
{
|
||||
$imagick = str_replace('\\', '/', getenv('MAGICK_HOME'));
|
||||
$imagick = str_replace('\\', '/', $magic_home);
|
||||
}
|
||||
|
||||
return $imagick;
|
||||
|
|
|
@ -416,9 +416,11 @@ if ($stage == 0)
|
|||
|
||||
$exe = ((defined('PHP_OS')) && (preg_match('#win#i', PHP_OS))) ? '.exe' : '';
|
||||
|
||||
$magic_home = getenv('MAGICK_HOME');
|
||||
|
||||
// Imagemagick are you there? Give me a sign or a path ...
|
||||
$img_imagick = '';
|
||||
if (empty(getenv('MAGICK_HOME')))
|
||||
if (empty($magic_home))
|
||||
{
|
||||
$locations = array('C:/WINDOWS/', 'C:/WINNT/', 'C:/WINDOWS/SYSTEM/', 'C:/WINNT/SYSTEM/', 'C:/WINDOWS/SYSTEM32/', 'C:/WINNT/SYSTEM32/', '/usr/bin/', '/usr/sbin/', '/usr/local/bin/', '/usr/local/sbin/', '/opt/', '/usr/imagemagick/', '/usr/bin/imagemagick/');
|
||||
$path_locations = str_replace('\\', '/', (explode(($exe) ? ';' : ':', getenv('PATH'))));
|
||||
|
@ -441,7 +443,7 @@ if ($stage == 0)
|
|||
}
|
||||
else
|
||||
{
|
||||
$img_imagick = str_replace('\\', '/', getenv('MAGICK_HOME'));
|
||||
$img_imagick = str_replace('\\', '/', $magic_home);
|
||||
}
|
||||
|
||||
?>
|
||||
|
|
Loading…
Add table
Reference in a new issue