Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I have a single drupal installation running two different sites. This is done by making a seperate folder in the sites folder for each domain and putting in a settings.php file. IMCE no longer works with a multisite setup. The browse icon is present but when I click on it the window pops up and I get "Directory Error!".
This installation of IMCE was working before I converted to a multisite setup, and it still works on other installation I have that are not multisite.
Comment | File | Size | Author |
---|---|---|---|
#6 | imce_set.js.patch.txt | 919 bytes | ufku |
#5 | imce.module.patch_1.txt | 892 bytes | ufku |
#3 | imce.sitebase.patch.txt | 1.21 KB | mr700 |
Comments
Comment #1
ufku CreditAttribution: ufku commentedis your file system path writable by php. check it at admin/settings under file system settings.
Comment #2
tbartels CreditAttribution: tbartels commentedYes, I was using it successfully as a single instance install prior to encountering this.
permissions are:
drwxrwxrwx 3 root www 4096 Oct 4 15:46 files
Comment #3
mr700 CreditAttribution: mr700 commentedI'm working with 4.7.x and multisite configuration too (one active site for now). My tinymce and imce are in drupal/sites/site.name/modules and the site is in subfolder (ex: http://localhost/drupal/). 'Hacking' imce_set.js a bit helped: I changed
to
which obviously will not work if you installed tinymce in drupal/modules. Maybe checking for '/modules/' and checking which one exists could solve the problem for everyone, like this:
I'm attaching a patch for the last one.
Comment #4
ufku CreditAttribution: ufku commentedthank you for the patch. i think getting the right url with javascript for all configurations is not possible since one may setup drupal under sub directories like domain.com/modules or domain.com/sites. that's why searching for these words is not sufficient. i think this URL thing should be set by php. may be a javascript variable refering to url('imce/browse'). i'll look into this.
thanks again.
Comment #5
ufku CreditAttribution: ufku commentedhere is the module patch to use with the imce_set.js patch below.
Comment #6
ufku CreditAttribution: ufku commentedhere is the imce_set.js patch to use with imce.module patch
Comment #7
mr700 CreditAttribution: mr700 commentedYep, with these two patches it works for me.
Comment #8
ufku CreditAttribution: ufku commentedand as far as i tested it works with different multi-site configurations.
commited.
Comment #9
(not verified) CreditAttribution: commented