Php 带有KCFinder UserFilePath的FCKEditor
在我的web应用程序中,我使用FCKEditor编辑新闻。FCKEditor使用KCFinder在服务器上浏览文件或图像 在config.php(FCKEditor->connector->browser)中,我配置了userfilepath和userfileabsolutepath。UserFilePath包含完整的Php 带有KCFinder UserFilePath的FCKEditor,php,fckeditor,kcfinder,Php,Fckeditor,Kcfinder,在我的web应用程序中,我使用FCKEditor编辑新闻。FCKEditor使用KCFinder在服务器上浏览文件或图像 在config.php(FCKEditor->connector->browser)中,我配置了userfilepath和userfileabsolutepath。UserFilePath包含完整的http://www.domain.tld/images/files/path和UserFilesAbsolutePath包含相同的路径,但使用文档根而不是tld 但是,当我转到F
http://www.domain.tld/images/files/
path和UserFilesAbsolutePath包含相同的路径,但使用文档根而不是tld
但是,当我转到FCKEditor窗口并尝试添加文本链接时,首先打开对话框,然后单击浏览器服务器,当我双击文件时,我返回到对话框,路径如下:/images/files/xyz.pdf
(例如)
实际上我需要这样的路径:http://www.domain.tld/images/files/xyz.pdf
请查看场景并提供一些解决方案。StartupPath是CKFinder对象的属性。有关更多信息,请参阅 CKFinder包中包含了一个工作示例,展示了如何使用StartupPath:“\u samples/js/popups.html” 当CKFinder通过SetupFCKeditor方法连接到FCKeditor时,可以以类似的方式使用StartupPath 在javascript中,还可以使用以下语法:
CKFinder.SetupFCKeditor( oFCKeditor, { BasePath : '/ckfinder/', StartupPath :
'Images:/path/to/directory/' } ) ;
因此,对于CKFinder与FCKeditor集成时设置StartupPath的完整工作示例,只需遵循以下步骤:
- 打开
\u samples/js/fckeditor.html
- 注释掉这一行
(添加双斜杠-“/”://CKFinder.SetupFCKeditor(oFCKeditor,“../”)代码>
- 在下面一行添加以下代码:
CKFinder.SetupFCKeditor(oFCKeditor,{BasePath:'../../',StartupPath:'Images:/directory/'})代码> 其中,
是一个有效的启动路径,应该可以工作“Images:/directory/”
FCKEditor
与KCFinder
集成?我也有一些关于KCFinder
的知识。您是否将权限设置为0777
?是的,我想在浏览器中选择一个文件并返回FCKEditors对话框的路径。请查看此链接: