I am wondering how to limit the files shown in the TinyMCEPlugin and elFinder integration. I would like an admin user to be able to login and create a campaign. The user would Create the HTML email and upload images but only be able to see the files they have uploaded using their account and no other user images.
@littlered Allowing separate directories for each admin has been in the ckeditor plugin for a while. I have just added it to the TinyMCE plugin. You can update the plugin on the Manage Plugins page.
The plugin creates a subdirectory of UPLOADIMAGES_DIR
using the admin id (usually 1, 2, 3 etc) and the admin cannot navigate upwards. The URL of an image will therefore be something like this for admin id 2
https://mysite.com/upload/2/funny_cat.jpg
Thank you for your reply! I updated the TinyMCEPlugin however I am still able to see all images regardless of which user is logged in. I am on Version 2.4.0+20231128 and Update status indicates Plugin is up-to-date. Is there something else I need to install or a config setting I need to change?
@littlered Yes, I forgot to say you need to add this line to the config.php file
define('IMAGE_DIR_PER_ADMIN', true);
That worked, Super Easy. Thank you.
To extend this just a little further. Is there a way to allow all Super User Admin to see all images but a regular admin user can only see their own images?
@littlered You can try making a change to file admin/plugins/TinyMCEPlugin/connector_phplist.php
line 30 should be
if (defined('IMAGE_DIR_PER_ADMIN') && IMAGE_DIR_PER_ADMIN) {
change it to
if (defined('IMAGE_DIR_PER_ADMIN') && IMAGE_DIR_PER_ADMIN && !$_SESSION['logindetails']['superuser']) {
This will allow access to UPLOADIMAGES_DIR
and all subdirectories.
That worked perfectly!