using FCKeditor 2.4.2.
I have a site where I need to change the location to upload images to in the editor for different pages. I don't want to have to install the editor many times, just once. So I include the FCKeditor, instantiate it, and change the config uploads for the UserFiles directory. But when I click the image icon in the toolbar to upload an image, it goes the the orginal configuration directory instead of what I have. So I'm missing something.
Here's my code:
if I echo the config value, I get the new location, but any image uploading goes to the original directory. Yes, the new directory exists and has the correct permissions on it.
PS: What I find is weird, in the image properties dialog, depending on which option you use, the image will upload to a different location, either '/userfiles/' or '/userfiles/image/', why is that? Why not just be one spot regardless of which option on that panel the use to upload an image?
I have a site where I need to change the location to upload images to in the editor for different pages. I don't want to have to install the editor many times, just once. So I include the FCKeditor, instantiate it, and change the config uploads for the UserFiles directory. But when I click the image icon in the toolbar to upload an image, it goes the the orginal configuration directory instead of what I have. So I'm missing something.
Here's my code:
<? require_once($_Server['DOCUMENT_ROOT'] . 'lib/FCKeditor/fckeditor.php'); $fck = new FCKeditor('FCKeditor1'); $fck->Config['UserFilesPath'] = '/path/to/new/dir/userfiles/'; $fck->Create(); ?>
if I echo the config value, I get the new location, but any image uploading goes to the original directory. Yes, the new directory exists and has the correct permissions on it.
PS: What I find is weird, in the image properties dialog, depending on which option you use, the image will upload to a different location, either '/userfiles/' or '/userfiles/image/', why is that? Why not just be one spot regardless of which option on that panel the use to upload an image?