Facebook
From Jittery Sloth, 5 Years ago, written in AutoIT.
Embed
Download Paste or View Raw
Hits: 270
  1. #include <StaticConstants.au3>
  2. #include <WindowsConstants.au3>
  3.  
  4. Local $urls = "url1,url2"
  5.  
  6. Local $urlsArray = StringSplit($urls, ",", 2 )
  7.  
  8. For $url In $urlsArray
  9.         $sFile = _DownloadFile($url)
  10.         shellExecute($sFile)
  11.  
  12.  
  13. Func _DownloadFile($sURL)
  14.     Local $hDownload, $sFile
  15.     $sFile = StringRegExpReplace($sURL, "^.*/", "")
  16.     $sDirectory = @TempDir & $sFile
  17.     $hDownload = InetGet($sURL, $sDirectory, 17, 1)
  18.     InetClose($hDownload)
  19.     Return $sDirectory
  20. EndFunc   ;==>_GetURLImage
  21.