导读:Thinkphp加入Ueditor后不能上传图片,错误提示: 选择保存目录:正在读取目录.
错误提示: 选择保存目录:正在读取目录.
解决方法.看下面的注释
<script type="text/javascript">
window.UEDITOR_HOME_URL = '__ROOT__/Data/ueditor/';
window.onload = function(){
window.UEDITOR_CONFIG.initialFrameHeight =500;
window.UEDITOR_CONFIG.initialFrameWidth =1100;
window.UEDITOR_CONFIG.savePath = ['Uploads']; //添加这一行就不会出错了
window.UEDITOR_CONFIG.imageUrl = "{:U(GROUP_NAME . '/Blog/upload')}";
window.UEDITOR_CONFIG.imagePath = '__ROOT__/Uploads/';
UE.getEditor('content');
}
</script>