Quantcast
Channel: PowerShell.com – PowerShell Scripts, Tips, Forums, and Resources: Active Threads
Viewing all articles
Browse latest Browse all 8411

powershell - Invoke-WebRequest - sourceforge urls/redirection/dynamic conten

$
0
0

Hallo,

I try to use Invoke-WebRequest CmdLet in Powershell for downloading OpenOffie 4.0:

Invoke-WebRequest-Uri"http://downloads.sourceforge.net/project/openofficeorg.mirror/4.0.0/binaries/en-US/Apache_OpenOffice_4.0.0_Win_x86_install_en-US.exe?r=http%3A%2F%2Fwww.openoffice.org%2Fdownload%2Findex.html&ts=1375536623&use_mirror=heanet"-OutFile e:\Apache_OpenOffice_4.0.0_Win_x86_install_en-US.exe 

What I get is the website and not the file. Firefox follows the redirection and gets the correct file. How can I tell "Invoke-WebRequest" that I like to download the redirection an not the current website.

Thanks!


Viewing all articles
Browse latest Browse all 8411

Trending Articles