public
Last active

Tiny bootstrap scripts for curlIE

  • Download Gist
curlIE-bootstrap-micro.js
JavaScript
1 2
// Does not handle non-ASCII
(W=new ActiveXObject("WinHttp.WinHttpRequest.5.1")).Open("GET","http://curlie.googlecode.com/svn/trunk/curlIE.wsf");W.Send();WScript.Echo(W.ResponseText)
curlIE-bootstrap-micro.vbs
Visual Basic
1 2
' Does not handle non-ASCII
Set W=CreateObject("WinHttp.WinHttpRequest.5.1"):W.Open"GET","http://curlie.googlecode.com/svn/trunk/curlIE.wsf":W.Send:WScript.Echo W.ResponseText
curlIE-micro.vbs
Visual Basic
1 2
' Does not handle non-ASCII
Set W=CreateObject("WinHttp.WinHttpRequest.5.1"):W.Open"GET",WScript.Arguments(0):W.Send:WScript.Echo W.ResponseText
curlIE-mini.js
JavaScript
1 2
// Loves binary!
var A=WScript.Arguments,X=ActiveXObject,W=new X("WinHttp.WinHttpRequest.5.1"),F=new X("ADODB.Stream");W.Open("GET",A(0));W.Send();F.Type=1;F.Open();F.Write(W.ResponseBody);F.SaveToFile(A(1));
curlIE-mini.vbs
Visual Basic
1 2
' Loves binary
Set A=WScript.Arguments:Set W=CreateObject("WinHttp.WinHttpRequest.5.1"):W.Open"GET",A(0):W.Send:Set S=CreateObject("ADODB.Stream"):S.Type=1:S.Open:S.Write W.ResponseBody:S.SaveToFile A(1)

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.