From: Scott González Date: Tue, 17 May 2011 14:02:22 +0000 (-0400) Subject: Tabs: Escape all special characters when sanitizing hash selectors. Fixes #4681 ... X-Git-Tag: 1.9m5~18 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=5f10fa6511ae1965088926217776692a3f5663cb;p=jquery-ui.git Tabs: Escape all special characters when sanitizing hash selectors. Fixes #4681 - Tabs: _sanitizeSelector needs to escape '.'. --- diff --git a/ui/jquery.ui.tabs.js b/ui/jquery.ui.tabs.js index 36c9000ef..7702c1e4b 100644 --- a/ui/jquery.ui.tabs.js +++ b/ui/jquery.ui.tabs.js @@ -144,7 +144,7 @@ $.widget( "ui.tabs", { _sanitizeSelector: function( hash ) { // we need this because an id may contain a ":" - return hash ? hash.replace( /:/g, "\\:" ) : ""; + return hash ? hash.replace( /[!"$%&'()*+,.\/:;<=>?@[\]^`{|}~]/g, "\\$&" ) : ""; }, refresh: function() {