I'm probably going about this all wrong....

But I've been using IMCE to support file uploads to my site for scripts and stuff for a MUD I play....

I have the basic IMCE correctly set up, and I was using the snippet that was an example...

php: return 'users/'.$user->name;

I also set up users as browseable by all (we're all about sharing code), but only the $user can upload/delete/create subdirs in their own folder. The problem I'm running into is (yes, I have sub-directories checked) I can't seem to allow uploads to subdirs that the users create in their own folder....



I can see all the other user's dirs fine (Ace), but I can't upload to tintin (my subdir) or browse other subdirs (Ace->Testing)

I'm assuming there's a code snippet or something stupid I missed....

Any suggestions?


karvec’s picture

Solved, had to remove all code/user permissions, rebuild permissions, and then add the permissions for User-1 again.

Taxoman’s picture

Category: bug » support
Status: Active » Closed (works as designed)
florisla’s picture

I was just bitten by a very similar issue:

  • Creating subfolders was still possible
  • Browsing them was no problem either
  • But the 'Upload' button was not present in the subfolders (only active in the 'users/'.$user->name folder itself)

The only thing that was changed was that I added new permissions (below the existing line regarding folder 'users/'.$user->name) on folder 'users', read-only, including subfolders.

What got rid of this issue was removing the line with permissions on folder 'users/'.$user->name , and add exactly the same permissions again *below* the line with 'users' permissions.

bradp’s picture

Issue summary: View changes

I believe that adding all permissions to 'users' on a line below 'users/'.$user->name will give everyone write access to everyone else's folder. I couldn't get the php line correct to try it.

I found the best way to do this was to give read only access to all folders using /.
Then on the line below it:
/php: return 'users/'.$user->name;

Before doing this I had similar problems with not being able to write to newly created directories. Apparently, putting /. with read only access after the user->name line overrides the write permissions for sub folders.

A note about this in the help paragraph below the Directories field would be helpful.