From 62af563fc8129399b6fd3e7dbbe709c91b0c86b0 Mon Sep 17 00:00:00 2001 From: haneul Date: Mon, 12 Oct 2009 10:04:37 +0000 Subject: [PATCH] #18273822 : fixed bugs with non-default SSL port git-svn-id: http://xe-core.googlecode.com/svn/sandbox@6851 201d5d3c-b55e-5fd7-737f-ddc643e51545 --- common/js/xml_handler.js | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/common/js/xml_handler.js b/common/js/xml_handler.js index 3320cfcd4..085fdf91b 100644 --- a/common/js/xml_handler.js +++ b/common/js/xml_handler.js @@ -105,12 +105,11 @@ function xml_handlerRequest(callBackFunc, xmlObj, callBackFunc2, response_tags, if(typeof(https_port)!='undefined' && https_port != 443) port = https_port; var _u1 = xCreateElement('a'); _u1.href = url; - var targetUrl = ''; - if(port == 443) targetUrl = 'https://'; - else targetUrl = 'http://'; - targetUrl += _u1.hostname; + var targetUrl = 'https://'; + targetUrl += _u1.hostname.replace(/:([0-9]+)$/,''); if(port != 443) targetUrl += ':'+port; - targetUrl += _u1.pathname; + if(_u1.pathname[0] != "/") targetUrl += "/"; + targetUrl += _u1.pathname; targetUrl = targetUrl.replace(/\/$/,''); this.xml_path = targetUrl + '/index.php'; }