File tree Expand file tree Collapse file tree 2 files changed +9
-10
lines changed
sources/net.sf.j2s.ajax/store/net/sf/j2s/store Expand file tree Collapse file tree 2 files changed +9
-10
lines changed Original file line number Diff line number Diff line change @@ -15,10 +15,11 @@ private SimpleStore() {
1515 /**
1616 * @j2sNative
1717 * var ua = navigator.userAgent.toLowerCase ();
18- * var isIE = ( ua.indexOf ("msie") != -1) ;
18+ * var isOldIE = ua.indexOf ("msie 5.5 ") != -1 || ua.indexOf ("msie 5.0") != -1 ;
1919 * var cookieURL = window["j2s.xss.cookie.url"];
20- * var isLocal = window.location.protocol == "file:";
21- * if (!isLocal && cookieURL != null && !isIE) {
20+ * var isLocal = window.location.protocol == "file:"
21+ * || window.location.host.toLowerCase ().indexOf ("localhost") != -1;
22+ * if (!isLocal && cookieURL != null && !isOldIE) {
2223 * this.store = new net.sf.j2s.store.XSSCookieStore(cookieURL);
2324 * } else {
2425 * this.store = new net.sf.j2s.store.CookieStore();
Original file line number Diff line number Diff line change 88 *
99 * @j2sSuffix
1010 * var ua = navigator.userAgent.toLowerCase ();
11- * var isIE = ( ua.indexOf ("msie") != -1) ;
11+ * var isOldIE = ua.indexOf ("msie 5.5 ") != -1 || ua.indexOf ("msie 5.0") != -1 ;
1212 * var xssCookieURL = window["j2s.xss.cookie.url"];
13- * var isLocal = window.location.protocol == "file:";
14- * if (!isLocal && xssCookieURL != null && !isIE) {
13+ * var isLocal = window.location.protocol == "file:"
14+ * || window.location.host.toLowerCase ().indexOf ("localhost") != -1;
15+ * if (!isLocal && xssCookieURL != null && !isOldIE) {
1516 * net.sf.j2s.store.XSSCookieStore.initialize(xssCookieURL);
1617 * }
1718 */
@@ -32,10 +33,7 @@ public XSSCookieStore(String url) {
3233 /**
3334 * @j2sNative
3435var ua = navigator.userAgent.toLowerCase ();
35- var isIE = (ua.indexOf ("msie") != -1);
36- if (!isIE) {
37- document.domain = document.domain;
38- }
36+ document.domain = document.domain;
3937var xssIfr = document.getElementById ("xss-cookie");
4038if (xssIfr != null) {
4139 return;
You can’t perform that action at this time.
0 commit comments