Opened 17 years ago
Closed 12 years ago
#1652 closed New Feature (fixed)
Change file/image browser startup folder programmatically
Reported by: | Thomas Tallyce | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | File Browser | Version: | FCKeditor 2.5 |
Keywords: | Cc: |
Description
Feature request: there doesn't seem to be a way to change the file browser startup folder programmatically.
E.g. supposing one was editing a page /path/to/bar.html it would be useful to be able to set the file/image browser to the same folder, /path/to/ as that may well be the most logical place for files/images to be looked for first.
http://sourceforge.net/tracker/index.php?func=detail&aid=1498629&group_id=75348&atid=543655 mentions this request from someone else.
Change History (5)
comment:1 Changed 17 years ago by
Keywords: | startup removed |
---|
comment:2 Changed 17 years ago by
Type: | Bug → New Feature |
---|
comment:3 Changed 17 years ago by
The change in frmFolders.html SetResourceType( type ) (refered above as line 171) is wrong, because when the user changes the resource type then we must reload the base folder for that type as the current folder probably won't exist for the new file type.
The change in
window.onload = function() { oListManager.Init() ; LoadFolders( oConnector.CurrentFolder ) ; }
would be right, if oConnector.CurrentFolder points to the proper folder, but the change in browser.html is wrong, because the current Folder isn't passed as a parameter to the file manager so it gets set to an empty string and the connector might not be ready to handle that case (and anyway it doesn't get the current folder).
So this patch would need a way to properly get the current folder from the opener window or something similar.
Moved from Sourceforge.
Original author: AlfonsoML
comment:4 Changed 17 years ago by
Keywords: | Confirmed added |
---|
comment:5 Changed 12 years ago by
Resolution: | → fixed |
---|---|
Status: | confirmed → closed |
File browser is no longer used with CKEditor. A separate application CKFinder was created for that purpouse and it has possibility to set startup folder.
Change File Browser startup folder
The default file browser won't start any where but '/'.
In editor/filemanager/browser/default/frmfolders.html, on line 171
'LoadFolders( '/' ) ;'
needs to be
'LoadFolder( oConnector.CurrentFolder );'
And a few lines later
'LoadFolders( '/' ) ;'
needs to be
'LoadFolders( oConnector.CurrentFolder );'
And then in /editor/filemanager/browser/default/browser.html on line 36
'oConnector.CurrentFolder = '/' ;'
needs to be
'oConnector.CurrentFolder = GetUrlParam('CurrentFolder' ) ;'
Moved from http://sourceforge.net/tracker/index.php?func=detail&aid=1498629&group_id=75348&atid=543655[[BR]] Original author: anonymous