• Post Reply Bookmark Topic Watch Topic
  • New Topic

How To Upload a File by Using XMLHTTP  RSS feed

 
Ranch Hand
Posts: 105
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have this problem I want to upload files(attachments) from client side to server using AJAX.

How do I upload a Binary Stream by Using XMLHTTP(AJAX)?

If I can see a sample script or something to read to help me solve this slight problem. Thanks.
[ July 13, 2006: Message edited by: Ola Daniel ]
 
Rancher
Posts: 42975
76
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There's no need to use AJAX (and indeed no way to do so). Just use the regular HTTP file upload facilities. JavaScript as implemented in current browsers does not support file I/O.
 
Ola Daniel
Ranch Hand
Posts: 105
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I guess ill stick to regular http file upload methods then if it is not possible using AJAX.
 
author
Rancher
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The XMLHttpRequest object does not support multi part file uploads. You would have to post it to an iframe (That is what google does with gmail)

Eric
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!