请问如何用WinInet送POST命令上传图片,将相应的数据提交服务器,并读取返回结果? 急?
解决方案 »
- windows下关于多线程的问题。大家帮我分析下。
- MFC CListCtrl 控件怎么样才能写入数据
- debug下程序在调用com函数时 出现 KERNEL32.DLL 0xE06D7363: Microsoft C++ Exception.
- 怎样拦截发送的数据
- 请问如何提取网页内链接?
- VC里怎么用2000的Schedule Tasks做备忘提醒?
- CreateThread函数在什么时候返回?
- 一个拖拽图像的问题。
- 如何判断截取字符串时,是否断在汉字中间
- IP欺骗怎么实现?
- 有没有什么好的控件来显示文本,可编辑文本的显示位置, 我用它来做插图说明,否则要一行一行的自己TEXTOUT
- 能在状态栏上画图吗?
inter="------------------------------7d2256155c02de";
s="--"+inter+#13#10+"Content-Disposition: form-data; name=\"image_tmp\"; filename=\"pathto\img.jpg\"\r\nContent-Type: image/jpg\r\n+文件内容+"\r\n--"+inter+"--\r\n";
POST /33143/upload.php HTTP/1.1
Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, application/x-shockwave-flash, application/vnd.ms-powerpoint, application/vnd.ms-excel, application/msword, */*
Referer: http://www.cneme.com/33143/upload.php
Accept-Language: zh-cn
Content-Type: multipart/form-data; boundary=---------------------------7d3201258708a0
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)
Host: www.cneme.com
Content-Length: 8283
Connection: Keep-Alive
Cache-Control: no-cache
Cookie: PHPSESSID=d95c40fd9945fac6a279636026f64273? P 9 安AV? 郘=鉲 郘 , E ?]@ €%? A蔱 9 P-$C鶹缐PH? -----------------------------7d3201258708a0
Content-Disposition: form-data; name="MAX_FILE_SIZE"409600000
-----------------------------7d3201258708a0
Content-Disposition: form-data; name="userfile[]"; filename="C:\Documents and Settings\donald\My Documents\My Pictures\railcom.gif"
Content-Type: image/gifGIF89a?( ? 骀缂冀們吚览卩轷鼹螋?(W7tA丅n?e朥r標皱臆楣九捭?>?=?1j1h&QB?<€<;~:|9{9y8w7u0f/e-aA?@???>?=?=?遦 亨BC?w"s┿+事畝 矦s$詌騐甡D躃繞 ?樹B縕u咀偒? 紁 $\
?4?p@#Px#0$p€!PX 裶u?靯G?堾(?s?s<?,噑/?2w?J(
eR揁?at 篳 ??+婐;ⅱ.鋻 ?L
?\?綻U澿?YWz?_€M;?A?X m??啡?0 ;
-----------------------------7d3201258708a0
Content-Disposition: form-data; name="userfile[]"; filename=""
Content-Type: application/octet-stream
-----------------------------7d3201258708a0
Content-Disposition: form-data; name="userfile[]"; filename=""
Content-Type: application/octet-stream
-----------------------------7d3201258708a0
Content-Disposi< 9 P 犐aV? 郘 , 郘=鉲 E (鞷@ 9櫘蔱
A P 9V缐-$`VP|?m < 9 P €qV? 郘 , 郘=鉲 E (鞹@ 9櫖蔱
A P 9V缐-$c鶳|三? ? P 9 €qV? 郘=鉲 郘 , E ?d@ €+B
A蔱 9 P-$c鶹缐P墍 tion: form-data; name="submit"开始上传
-----------------------------7d3201258708a0--
? 9 P ?zV? 郘 , 郘=鉲 E 皂U@ 9?蔱
A P 9V缐-$dUP|華 HTTP/1.1 200 OK
Date: Wed, 30 Jul 2003 05:38:42 GMT
Server: Apache/1.3.22 (Unix) PHP/4.0.6
X-Powered-By: PHP/4.0.6
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: private, max-age=10800, pre-check=10800
Last-Modified: Mon, 19 May 2003 12:14:12 GMT
Keep-Alive: timeout=15, max=100
Connection: Keep-Alive
Transfer-Encoding: chunked
Content-Type: text/html; charset=gb2312762
文件<railcom.gif>成功上传为<railcom0.gif><br> <!--script>