[Commits] r494 - apps/opengeo/geoexplorer/trunk/lib
commits at geoext.org
commits at geoext.org
Tue Apr 28 16:19:48 CEST 2009
Author: ahocevar
Date: 2009-04-28 16:19:48 +0200 (Tue, 28 Apr 2009)
New Revision: 494
Modified:
apps/opengeo/geoexplorer/trunk/lib/GeoExplorer.js
Log:
don't use the non-API function createURLObject any more, because it does not work as expected in IE.
Modified: apps/opengeo/geoexplorer/trunk/lib/GeoExplorer.js
===================================================================
--- apps/opengeo/geoexplorer/trunk/lib/GeoExplorer.js 2009-04-28 12:22:11 UTC (rev 493)
+++ apps/opengeo/geoexplorer/trunk/lib/GeoExplorer.js 2009-04-28 14:19:48 UTC (rev 494)
@@ -93,13 +93,20 @@
* Method: initCapabilities
*/
initCapabilities: function() {
- var urlObj = OpenLayers.Util.createUrlObject(this.ows);
- var url = urlObj.protocol + "//" +
- urlObj.host + urlObj.pathname + "?" +
- Ext.urlEncode(Ext.apply(urlObj.args, {
- SERVICE: "WMS",
- REQUEST: "GetCapabilities"
- }));
+ var url;
+ var args = {
+ SERVICE: "WMS",
+ REQUEST: "GetCapabilities"
+ };
+ var argIndex = this.ows.indexOf("?");
+ if(argIndex > -1) {
+ var search = this.ows.substring(this.ows.indexOf("?")+1);
+ var url = this.ows.replace(search, Ext.urlEncode(Ext.apply(
+ Ext.urlDecode(search), args
+ )));
+ } else {
+ url = this.ows + "?" + Ext.urlEncode(args);
+ }
if(this.proxy) {
url = this.proxy + encodeURIComponent(url);
}
More information about the Commits
mailing list