From 34882b7125196eee5ea1c7c0eda8b60e1ecd64f1 Mon Sep 17 00:00:00 2001 From: Slava Date: Mon, 21 Nov 2016 20:53:45 +0200 Subject: [PATCH] fix file select after upload in ckeditor --- filebrowser/static/filebrowser/js/FB_CKEditor.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/filebrowser/static/filebrowser/js/FB_CKEditor.js b/filebrowser/static/filebrowser/js/FB_CKEditor.js index 95207b3..819cbc4 100755 --- a/filebrowser/static/filebrowser/js/FB_CKEditor.js +++ b/filebrowser/static/filebrowser/js/FB_CKEditor.js @@ -5,10 +5,12 @@ function ProtectPath(path) { } function gup( name ) { + var url = encodeURI(window.location.href); + url = url.replace(/&/g, '&'); name = name.replace(/[\[]/,"\\\[").replace(/[\]]/,"\\\]"); var regexS = "[\\?&]"+name+"=([^&#]*)"; var regex = new RegExp(regexS); - var results = regex.exec(window.location.href); + var results = regex.exec(url); if(results == null) return ""; else