schnibble Posted January 21, 2007 Share Posted January 21, 2007 how can i receiv with TCPSend and TCPRecv a large Webpage? My current function is: CODETCPStartup ( ) $ip = TCPNameToIP(xyz) $socket = TCPConnect( $ip, 80 ) $data = "GET /index.html HTTP/1.1" $receivtmp = "" $receiv = "" $send = TCPSend ( $socket, $data ) While Not $receivtmp $receivtmp = TCPRecv ( $socket, 10000 ) Sleep(100) WEnd $receiv = $receivtmp While $receivtmp $receivtmp = TCPRecv ( $socket, 10000 ) $receiv = $receiv & $receivtmp Sleep(100) WEnd TCPShutdown () but sometimes it dont work.. can i use a dll or a udf? Link to comment Share on other sites More sharing options...
Helge Posted January 21, 2007 Share Posted January 21, 2007 Try _INetGetSource. Link to comment Share on other sites More sharing options...
WhiteTiger Posted January 21, 2007 Share Posted January 21, 2007 Try _INetGetSource.i think that will be a load easyer but i have done it With tcp with a litle searching on Wikipedia and using Ethereal :-) Link to comment Share on other sites More sharing options...
schnibble Posted January 21, 2007 Author Share Posted January 21, 2007 but the website is not only a simple sideas example:POST /forum/index.php?act=Search&CODE=01 HTTP/1.1Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, application/x-shockwave-flash, application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword, */*Referer: http://www.autoitscript.com/forum/index.phpAccept-Language: de-chContent-Type: application/x-www-form-urlencodedAccept-Encoding: gzip, deflateUser-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.1.4322)Host: www.autoitscript.comContent-Length: 36Connection: Keep-AliveCache-Control: no-cacheforums=all&keywords=autoit&x=14&y=20and the result site is large Link to comment Share on other sites More sharing options...
WhiteTiger Posted January 21, 2007 Share Posted January 21, 2007 POST /forum/index.php?act=Search&CODE=01 HTTP/1.0Accept: */*Referer: http://www.autoitscript.com/forum/index.phpHost: www.autoitscript.comConnection: Keep-Aliveforums=all&keywords=autoit&x=14&y=20thats a lot shorter and works well to :-) Link to comment Share on other sites More sharing options...
schnibble Posted January 22, 2007 Author Share Posted January 22, 2007 i know its only a example... no solution for get / post websites with tcpsend / tcpreceiv Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now