By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,192 Members | 855 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,192 IT Pros & Developers. It's quick & easy.

Sending file over CGI (C++)

P: 24
Hi everybody!

I have a problem. I need to upload file over CGI script(on C++).

For example, there is some form that makes user choose file, and after pressing "Submit" button script must write this file to server. The problem is, that, form return only filename, but does not show it's content... Do you have any ideas how it's possible to get file content?
Expand|Select|Wrap|Line Numbers
  1. <form method="get"><input type="file" name="filename"><input type="submit" name="submit" value="OK"></form>
Let's say, that it is that form. It returns somehow only filename... Is it possible to get file content?

Actually, if I could get that file's data, it's not a huge problem to write it to the hard disk, but how to get it's data?

PS. Maybe I missed some options in the form?
Jun 3 '07 #1
Share this question for a faster answer!
Share on Google+

Post your reply

Sign in to post your reply or Sign up for a free account.