SyntaxFix
Write A Post
Hire A Developer
Questions
var getBasePath = function(url) { var r = ('' + url).match(/^(https?:)?\/\/[^/]+/i); return r ? r[0] : ''; };