In the past, I predefined the auto-resize value for a specific folder in ckFinder to change any image that a user uploads to that folder. I do this by adding a little code to the config.php file as follows:
// This next block sets the default max image size and quality $config['Images'] = Array( 'maxWidth' => 1600, 'maxHeight' => 1200, 'quality' => 80); // Here we override those settings for a given folder if(isset($_GET['currentFolder']) && urldecode($_GET['currentFolder']) == '/some-folder-name/'){ $config['Images']['maxWidth'] = 150; $config['Images']['maxHeight'] = 150; }
I would suspect that you can do a similar hack, perhaps using the values ββof $ _SESSION. Ask the user to select the auto-resize values ββthey need and save them in their $ _SESSION. Then, in your configuration file, find this session value. Something like:
if(isset($_SESSION['resize_w']) && isset($_SESSION['resize_h']) ){ $config['Images']['maxWidth'] = $_SESSION['resize_w']; $config['Images']['maxHeight'] = $_SESSION['resize_h']; }
Note that you will need to call session_start () in the config.php file if you have not already done so.
Micah
source share