i am new to fckeditor. everything seems to be working fine, except for the file browser. if i upload a file, it works correctly, but does not show the links in the file browser. the files on the server are in the right place, etc. the directories are chmod 777. here are my config settings. any help would be appreciated. thanks...
File manager connector:
// 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'] = '/kb_upload/' ;
// 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['UserFilesPath'] = $conf['fck_upload_dir']; {this variable = '/htdocs/www/kb_upload'}
PHP file uploader:
// SECURITY: You must explicitelly enable this "uploader".
$Config['Enabled'] = true ;
// Set if the file type must be considere in the target path.
// Ex: /UserFiles/Image/ or /UserFiles/File/
$Config['UseFileType'] = true ;
// Path to uploaded files relative to the document root.
$Config['UserFilesPath'] = '/kb_upload/' ;
// 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'] = '' ;
File manager connector:
// 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'] = '/kb_upload/' ;
// 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['UserFilesPath'] = $conf['fck_upload_dir']; {this variable = '/htdocs/www/kb_upload'}
PHP file uploader:
// SECURITY: You must explicitelly enable this "uploader".
$Config['Enabled'] = true ;
// Set if the file type must be considere in the target path.
// Ex: /UserFiles/Image/ or /UserFiles/File/
$Config['UseFileType'] = true ;
// Path to uploaded files relative to the document root.
$Config['UserFilesPath'] = '/kb_upload/' ;
// 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'] = '' ;
RE: file browser is empty
more info...
i found the 'test' html and this is the output i'm getting using the php connector:
XML Parsing Error: no element found
Location: http://www.clubrunner.net/kb/admin/tool ... ntFolder=/
Line Number 3, Column 1:
RE: file browser is empty
PHP Fatal error: Call to undefined function: utf8_encode() in /htdocs/www/kb/admin/tools/FCKeditor/editor/filemanager/browser/default/connectors/php/util.php on line 35
i'm using php4, why isn't this working?
RE: file browser is empty
I was having a similar issue with nothing being shown in the file browser:
Everything works fine (file uploader included) except that no links will show when I use the browser. I get a javascript error:
Line: 104
Char: 2
Error: Object Required
Code: 0
URL: http://<MYDOMAIN>/FCKeditor/editor/filemanager/browser/default/frmresourcelist.html
The pertinant code is from the GetFoldersAndFilesCallBack function:
Code:
// Get the current folder path.
var oNode = fckXml.SelectSingleNode( 'Connector/CurrentFolder' ) ;
var sCurrentFolderPath = oNode.attributes.getNamedItem('path').value ;
var sCurrentFolderUrl = oNode.attributes.getNamedItem('url').value ;
Line 104 is the sCurrentFolderPath line.
I traced all the way into the commands.php file using mail() to send myself debug info. It was actually reading the files, as I dumped $aFolders and $aFiles into the email and got this:
aFolders: 0 = <Folder name="test" />
aFiles: 0 = <File name="header.jpg" size="72" /> 1 = <File name="alien1.jpg" size="15" /> 2 = <File name="footerBG.gif" size="5" /> 3 = <File name="mainBodyBG.gif" size="9" />
It even showed that folder creation was working, since "test" is a folder I created from within the browser!
This was a tough one. Lots of people are having problems with this and no good answers. Well, I finally figured this one out using the test file located at /FCKeditor/editor/filemanager/browser/default/connectors/test.html. I don't know why that test page was hard for me to find, but once I found it I fixed the problem in 5 mins. It was odd though...
So, I am dynamically assigning the $Config['UserFilesPath'] and $Config['UserFilesAbsolutePath'] variables based upon which domain is being managed in the proprietery CMS I created using FCK as the editor. In order to use the classes I built for the CMS, I was including a common.php file, which contained DB connection info and classes that recognize which domain was being managed.
Anyway, when I included this file, it was including another file, common_functions.php (can you guess what was in there?) Well, test.html indicated that the problem was occuring in /FCKeditor/editor/filemanager/browser/default/connectors/php/basexml.php. It was saying that header info could not be sent out because it had already been sent from common_functions.php on line 220.
So I go check out line 220 of common_functions.php and it was the very end of the file. However, there were two carriage returns after the closing ?> tag. I deleted these two carriage returns and saved it and BAM it works.
Apparently, when PHP included this file and encounted the two CR's it sent them to the browser as output and this caused the basexml.php file to throw an error when it tried to send out header info to the browser.
I hope this helps anybody that might be banging their head on the desk like I was!
~DSNoe~