Hi
FCKeditor does a great job to style the content. I want the user to upload the files to a directory which is not under webroot (and so inaccessible to general public). The main idea is to allow the user to upload the files to a folder, and feed the downloads thru a php page (for tracking, authentication etc) Once file is uploaded, the CMS content manager changes the url to something like /downloads.php?file=<uploaded file name>
I tried absolutepath but it doesnt work. I hope theres a quick solution to this. Only option I can think of is: put an .htaccess in the webroot/files/ folder. But not before trying other options.
cheers
FCKeditor does a great job to style the content. I want the user to upload the files to a directory which is not under webroot (and so inaccessible to general public). The main idea is to allow the user to upload the files to a folder, and feed the downloads thru a php page (for tracking, authentication etc) Once file is uploaded, the CMS content manager changes the url to something like /downloads.php?file=<uploaded file name>
I tried absolutepath but it doesnt work. I hope theres a quick solution to this. Only option I can think of is: put an .htaccess in the webroot/files/ folder. But not before trying other options.
cheers
Re: Upload to a directory which is not below webroot
Well.. it's up to you which way you prefer to choose.
Server side integration article on FCKeditor wiki may help you: http://wiki.fckeditor.net/Developer's_G ... ntegration
Your mod_rewrite idea is quite clever and may be the right way to do it.
If you want to save your time, you may try CKFinder:
http://www.fckeditor.net/extras/ckfinder
it already has built-in support for serving files from outside the DocumentRoot.
Wiktor Walc
CTO, CKSource - http://cksource.com
--
Follow CKEditor on: Twitter | Facebook | Google+