Mar 9, 2012 #1 ehaze Technical User Oct 16, 2009 254 US http://www.taco.com/site/subsite/bean/cheese/nacho.aspx Using PowerShell, how would I go about parsing out each section of the above URL? What I'm trying to get from the URL: http://www.taco.comsite subsite bean cheese http://www.sharepointed.com/
http://www.taco.com/site/subsite/bean/cheese/nacho.aspx Using PowerShell, how would I go about parsing out each section of the above URL? What I'm trying to get from the URL: http://www.taco.comsite subsite bean cheese http://www.sharepointed.com/
Mar 9, 2012 #2 58sniper MIS Apr 25, 2004 9,152 US $url="http://www.taco.com/site/subsite/bean/cheese/nacho.aspx"$url.split("/") Do you have your Tek-Tips.com Swag? I've got mine! Stop by the new Tek-Tips group at LinkedIn. Upvote 0 Downvote
$url="http://www.taco.com/site/subsite/bean/cheese/nacho.aspx"$url.split("/") Do you have your Tek-Tips.com Swag? I've got mine! Stop by the new Tek-Tips group at LinkedIn.
Mar 9, 2012 1 #3 58sniper MIS Apr 25, 2004 9,152 US You could also do something like $url = "http://www.taco.com/site/subsite/bean/cheese/nacho.aspx"$url2 = $url.split("/") and then address each piece using $url2[x], such as $url2[0] $url2[1] etc. Do you have your Tek-Tips.com Swag? I've got mine! Stop by the new Tek-Tips group at LinkedIn. Upvote 0 Downvote
You could also do something like $url = "http://www.taco.com/site/subsite/bean/cheese/nacho.aspx"$url2 = $url.split("/") and then address each piece using $url2[x], such as $url2[0] $url2[1] etc. Do you have your Tek-Tips.com Swag? I've got mine! Stop by the new Tek-Tips group at LinkedIn.
Mar 9, 2012 Thread starter #4 ehaze Technical User Oct 16, 2009 254 US That did it! Thank you! http://www.sharepointed.com/ Upvote 0 Downvote