parsing - Use javascript to parse URL (not querystring) folder structure domain/parseThis/ -
I know how to parse the query string but I'm sending a format of: domainName / variable / somethingElseIDontCareAbout
I need to catch that middle part and so I can see what it says ... any help?
Thank you! Todd
If your original URL is something like if No, just change the number in the brackets. http://domainname.com/variable/ Else , you can use it:
document.location.href.split ("/") [3]
Comments
Post a Comment