From 3c45a928c36b89f28dd4df5ea0122ac8464972b1 Mon Sep 17 00:00:00 2001 From: rlx <0x0073@0x2620.org> Date: Mon, 26 Aug 2013 16:47:21 +0000 Subject: [PATCH] fix #1835 (in URLs, encode # in edit/text name or query) --- source/Ox.UI/js/Core/URL.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/Ox.UI/js/Core/URL.js b/source/Ox.UI/js/Core/URL.js index 0d60e02f..a6c7e61f 100644 --- a/source/Ox.UI/js/Core/URL.js +++ b/source/Ox.UI/js/Core/URL.js @@ -566,8 +566,8 @@ Ox.URL = function(options) { return Ox.decodeURIComponent(value).replace(/_/g, ' ').replace(Ox.char(9), '_'); } - function encodeValue(value, encodeSlash) { - var chars = (encodeSlash ? '/' : '') + '&|()=*%', + function encodeValue(value, isItem) { + var chars = isItem ? '/#%' : '#&|()=*%', ret = ''; value.toString().split('').forEach(function(char) { var index = chars.indexOf(char);