diff options
author | Meik Sievertsen <acydburn@phpbb.com> | 2006-07-01 19:11:52 +0000 |
---|---|---|
committer | Meik Sievertsen <acydburn@phpbb.com> | 2006-07-01 19:11:52 +0000 |
commit | 6df6eb0e601d459544b0cbcee063cf19c01bb37d (patch) | |
tree | c99b89abfafe03c69d5e0852abda5f4c0b98f155 /phpBB/includes/functions_posting.php | |
parent | 7ad5db1856f18edb5fb8e2cd784b1eb22d3dcbc1 (diff) | |
download | forums-6df6eb0e601d459544b0cbcee063cf19c01bb37d.tar forums-6df6eb0e601d459544b0cbcee063cf19c01bb37d.tar.gz forums-6df6eb0e601d459544b0cbcee063cf19c01bb37d.tar.bz2 forums-6df6eb0e601d459544b0cbcee063cf19c01bb37d.tar.xz forums-6df6eb0e601d459544b0cbcee063cf19c01bb37d.zip |
- add additional auth check to the permission roles modules
- added new function to return globally used expressions (get_preg_expression($mode)). This should be very helpful in getting wide spread similar checks (regular expressions) to one place reducing the risk of forgetting to change every location if you fix one. ;) We will add additional ones later, at the moment only the email check is retrieved...
- added "active module" var to the module class returning the current active module
- changed call to image magick
- add administrator to global moderators group by default
- extend auth_option column a little bit
- other bugfixes
git-svn-id: file:///svn/phpbb/trunk@6135 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/functions_posting.php')
-rw-r--r-- | phpBB/includes/functions_posting.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/phpBB/includes/functions_posting.php b/phpBB/includes/functions_posting.php index 127d7b2af4..70b568a5ed 100644 --- a/phpBB/includes/functions_posting.php +++ b/phpBB/includes/functions_posting.php @@ -521,9 +521,10 @@ function create_thumbnail($source, $destination, $mimetype) $used_imagick = false; - if ($config['img_imagick']) + // Only use imagemagick if defined and the passthru function not disabled + if ($config['img_imagick'] && function_exists('passthru')) { - passthru($config['img_imagick'] . 'convert' . ((defined('PHP_OS') && preg_match('#win#i', PHP_OS)) ? '.exe' : '') . ' -quality 85 -antialias -sample ' . $new_width . 'x' . $new_height . ' "' . str_replace('\\', '/', $source) . '" +profile "*" "' . str_replace('\\', '/', $destination) . '"'); + passthru(escapeshellcmd($config['img_imagick']) . 'convert' . ((defined('PHP_OS') && preg_match('#win#i', PHP_OS)) ? '.exe' : '') . ' -quality 85 -antialias -sample ' . $new_width . 'x' . $new_height . ' "' . str_replace('\\', '/', $source) . '" +profile "*" "' . str_replace('\\', '/', $destination) . '"'); if (file_exists($destination)) { $used_imagick = true; |