Tuesday, November 9, 2010

Build URL for webservices Ex: Lists.asmx

 var hrefParts = window.location.href.split('/');
            var wsURL = "";
            for (i = 0; i < (hrefParts.length - 2); i++) {
                if (i > 0)
                    wsURL += "/";
                wsURL += hrefParts[i];
            }
            wsURL += "/_vti_bin/lists.asmx";

No comments: