I've been trying to get the image uploads working for a few hours now and am having very little luck. I've gone threw all the documentation I can find on here and have specified the paths in the fallowing files:
-/FCKeditor/editor/filemanager/browser/default/connectors/php/config.php
--// SECURITY: You must explicitelly enable this --"connector". (Set it to "true").
--$Config['Enabled'] = true ;
--
--// Path to user files relative to the document --root.
--$Config['UserFilesPath'] = '/goclans/uploads/' ;
-/FCKeditor/editor/filemanager/upload/
--// SECURITY: You must explicitelly enable this --"uploader".
--$Config['Enabled'] = true ;
--
--// Path to uploaded files relative to the --document root.
--$Config['UserFilesPath'] = '/goclans/uploads/' ;
-/FCKeditor/fckconfig.js
--FCKConfig.ProtectedSource.Add(/<\?[\s\S]*?\?>/g--); //PHP style server side code
and some others all of which I found the instructions in http://wiki.fckeditor.net/UploadConfigF ... 8upload%29
The site is on a subdomain. Releative to httpdocs, the calling file is in /SR/. The uploads path is in /goclans/uploads/. The FCKeditor files are in /goclans/FCKeditor/. The calling files includes a file in /goclans/forum/ which includes the fckeditor and creates the form. FCKeditor seams to work fine witht he form, the data is submitted np. File uploads do not seam to work. When I click on the image upload, select an image, and click upload to server, it acts like it is sending a file, says waiting for guildwars.goclans.com... then just stops and does nothing. It does not upload the file, it does not create the img url. I tried using the server browser and it does not seam to be viewing the actual images directory. One it will not upload files in the server browser or create sub directories. Two I created a sub directory in the images folder I had created for FCKeditor and check in the server browser and it was not there. Thats about it for what I know to describe the problem. I've tried everything I can find on the wiki site to get it to work. I assume this thing is not looking at the right directory because the server browser doesn't seam to be even viewing correctly. But as far as I can tell I've set it all correctly. I would appreciate any help anyone can offer.
The form file is: (only include form related code...)
include_once('../goclans/FCKeditor/fckeditor.php');
$output .= '<form action="index.php?page=forum&action=insert&item=thread" method="POST" enctype="multipart/form-data">
<label for="thread_title">*Thread Title</label><input type="text" id="thread_title" name="thread_title" value="'.addcslashes($_POST['thread_title'],'"').'" size="40" maxlength="255" \><br \>';
echo $_SERVER['DOCUMENT_ROOT'];
$sBasePath = '/goclans/FCKeditor/';
$oFCKeditor = new FCKeditor('FCKeditor1') ;
$oFCKeditor->BasePath = $sBasePath ;
$oFCKeditor->Value = 'This is some <strong>sample text</strong>. You are using <a href="http://www.fckeditor.net/">FCKeditor</a>.' ;
$output .= $oFCKeditor->CreateHtml() ;
//$oFCKeditor->Create() ;
//$output .= '<label for="description">Thread Description</label><textarea id="FCKeditor1" name="description" rows="10" cols="40">'.addcslashes($_POST['description'],'"').'</textarea><br \>';
$output .= '<label for="category_id">Category</label>'.$forum->categorySelectOutput().'<br \>
<input type="submit" name="submit_post" value="Submit Post">';
Sun, 03/26/2006 - 18:02
#1
RE: Uploading images
I think I have the same problem. I´ve been working now for 5 days trying to upload images with FCKeditor. It works fine on my local computer, but on the remote server the upload funtion dosen´t work. I have been through a lot of forums about this issue, but I can´t find someone who can help me. Please help.
My configuration are for now:
global $Config ;
// SECURITY: You must explicitelly enable this "connector". (Set it to "true").
$Config['Enabled'] = true ;
// Path to user files relative to the document root.
$Config['UserFilesPath'] = URL.'http://elegantnails.dk/FCKeditor/UserFiles/' ;
// Fill the following value it you prefer to specify the absolute path for the
// user files directory. Usefull if you are using a virtual directory, symbolic
// link or alias. Examples: 'C:\\MySite\\UserFiles\\' or '/root/mysite/UserFiles/'.
// Attention: The above 'UserFilesPath' must point to the same directory.
$Config['UserFilesAbsolutePath'] = 'elegantnails.dk/FCKeditor/UserFiles/' ;
global $Config ;
// SECURITY: You must explicitelly enable this "uploader".
$Config['Enabled'] = true ;
// Path to uploaded files relative to the document root.
$Config['UserFilesPath'] = URL.'http://elegantnails.dk/FCKeditor/UserFiles/' ;
And my fckconfig.js looks like this:
var _FileBrowserLanguage = 'php' ; // asp | aspx | cfm | lasso | perl | php | py
var _QuickUploadLanguage = 'php' ; // asp | aspx | cfm | lasso | php
// Don't care about the following line. It just calculates the correct connector
// extension to use for the default File Browser (Perl uses "cgi").
var _FileBrowserExtension = _FileBrowserLanguage == 'perl' ? 'cgi' : _FileBrowserLanguage ;
FCKConfig.LinkBrowser = true ;
FCKConfig.LinkBrowserURL = FCKConfig.BasePath + 'filemanager/browser/default/browser.html?Connector=connectors/php/connector.php' + _FileBrowserLanguage + '/connector.' + _FileBrowserExtension ;
FCKConfig.LinkBrowserWindowWidth = FCKConfig.ScreenWidth * 0.7 ; // 70%
FCKConfig.LinkBrowserWindowHeight = FCKConfig.ScreenHeight * 0.7 ; // 70%
FCKConfig.ImageBrowser = true ;
FCKConfig.ImageBrowserURL = FCKConfig.BasePath + 'filemanager/browser/default/browser.html?Type=Image&Connector=connectors/php/connector.php' + _FileBrowserLanguage + '/connector.' + _FileBrowserExtension ;
FCKConfig.ImageBrowserWindowWidth = FCKConfig.ScreenWidth * 0.7 ; // 70% ;
FCKConfig.ImageBrowserWindowHeight = FCKConfig.ScreenHeight * 0.7 ; // 70% ;
FCKConfig.FlashBrowser = true ;
FCKConfig.FlashBrowserURL = FCKConfig.BasePath + 'filemanager/browser/default/browser.html?Type=Flash&Connector=connectors/php/connector.php' + _FileBrowserLanguage + '/connector.' + _FileBrowserExtension ;
FCKConfig.FlashBrowserWindowWidth = FCKConfig.ScreenWidth * 0.7 ; //70% ;
FCKConfig.FlashBrowserWindowHeight = FCKConfig.ScreenHeight * 0.7 ; //70% ;
FCKConfig.LinkUpload = true ;
FCKConfig.LinkUploadURL = FCKConfig.BasePath + 'filemanager/upload/' + FCKConfig.QuickUploadLanguage + '/upload.' + _QuickUploadLanguage ;
FCKConfig.LinkUploadAllowedExtensions = "" ; // empty for all
FCKConfig.LinkUploadDeniedExtensions = ".(php|php3|php5|phtml|asp|aspx|ascx|jsp|cfm|cfc|pl|bat|exe|dll|reg|cgi)$" ; // empty for no one
FCKConfig.ImageUpload = true ;
FCKConfig.ImageUploadURL = FCKConfig.BasePath + 'filemanager/upload/' + FCKConfig.QuickUploadLanguage + '/upload.' + _QuickUploadLanguage + '?Type=Image' ;
FCKConfig.ImageUploadAllowedExtensions = ".(jpg|gif|jpeg|png)$" ; // empty for all
FCKConfig.ImageUploadDeniedExtensions = "" ; // empty for no one
FCKConfig.FlashUpload = true ;
FCKConfig.FlashUploadURL = FCKConfig.BasePath + 'filemanager/upload/' + FCKConfig.QuickUploadLanguage + '/upload.' + _QuickUploadLanguage + '?Type=Flash' ;
FCKConfig.FlashUploadAllowedExtensions = ".(swf|fla)$" ; // empty for all
FCKConfig.FlashUploadDeniedExtensions = "" ; // empty for no one
Is there a person out there who can figure this out for me, please.
I don´t have much hair anymoore.
Robert
RE: Uploading images
I you are on a unix like server.
Try this, it worked for me.
make in your root dir a dir called
UserFiles chmod this to 777
in UserFiles make a dir called Image and chmod this to 777
do this for File, Flash and Media, with cmod less then 777 it DID NOT work. names are casesencetive.
your path=
$Config['UserFilesPath'] = URL.'http://elegantnails.dk/FCKeditor/UserFiles/' ;
my path= $Config['UserFilesPath'] = '/UserFiles/' ;
And this my sound strange but.
I had the same problem on a free hosting server, i uploaden my site to an other server and it worked.