I've cobbled together such a plugin.
It isn't pretty, but it seems to be working on my testbed site.
In the back-end there is a new menu called 'Client Files'
This lets you manage the client file areas, creating new ones, changing the password (to change a password, use the create form with an existing client name), deleting them (the 'X'), or managing them (click on the client are name).
Client areas are created under the data/other directory. The password is stored in each client area folder in a dot file.
Managing the client area lets you upload/replace, delete, and view files in the client area.
files are served by a helper php script included in the zip, as I could not find any other way to hook into the backend before headers were sent.
The front end is activated by using (% clientfiles %) in a page. This will be expanded to the whole front-end.
There is a login form. Once logged-in the client is given a list of their files which can be downloaded. I maintain the login using session variables.
I've never used sessions before so I hope I did it correctly. I serve the file using the same helper function when accessed from the front end out of sheer laziness as the code was already written. I suppose it could just be tied into the index-pretemplate hook as well to completely hide the backend helper.
Please give it a test. No idea if it will work with non-english character sets.
It needs cleanup, as many things should be moved into functions, and the whole UI needs to be prettied up, but I wanted to get it out for others to try.
Thanks,
EDIT: New version further down.
-Rob A>
It isn't pretty, but it seems to be working on my testbed site.
In the back-end there is a new menu called 'Client Files'
This lets you manage the client file areas, creating new ones, changing the password (to change a password, use the create form with an existing client name), deleting them (the 'X'), or managing them (click on the client are name).
Client areas are created under the data/other directory. The password is stored in each client area folder in a dot file.
Managing the client area lets you upload/replace, delete, and view files in the client area.
files are served by a helper php script included in the zip, as I could not find any other way to hook into the backend before headers were sent.
The front end is activated by using (% clientfiles %) in a page. This will be expanded to the whole front-end.
There is a login form. Once logged-in the client is given a list of their files which can be downloaded. I maintain the login using session variables.
I've never used sessions before so I hope I did it correctly. I serve the file using the same helper function when accessed from the front end out of sheer laziness as the code was already written. I suppose it could just be tied into the index-pretemplate hook as well to completely hide the backend helper.
Please give it a test. No idea if it will work with non-english character sets.
It needs cleanup, as many things should be moved into functions, and the whole UI needs to be prettied up, but I wanted to get it out for others to try.
Thanks,
EDIT: New version further down.
-Rob A>