├── README.md
├── aspx
├── index.html
└── savetofile.aspx
└── php
├── index.html
└── savetofile.php
/README.md:
--------------------------------------------------------------------------------
1 | Uploading Photos with HTML5
2 | =========
3 | Take a photo from mobile devices (Android, iOS and so on) with HTML5, and upload the image to remote servers.
4 |
5 | Blog
6 | -----------
7 |
8 | [Take a Photo and Upload it on Mobile Phones with HTML5][1]
9 |
10 | [1]:http://www.codepool.biz/tech-frontier/html5/take-a-photo-and-upload-it-on-mobile-phones-with-html5.html
11 |
--------------------------------------------------------------------------------
/aspx/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Take or select photo(s) and upload
8 |
9 |
112 |
113 |
114 |
115 |
116 |
117 |
138 |
139 |
140 |
141 |
--------------------------------------------------------------------------------
/aspx/savetofile.aspx:
--------------------------------------------------------------------------------
1 | <%@ Page Language="C#" %>
2 |
3 | <%
4 |
5 | HttpFileCollection files = HttpContext.Current.Request.Files;
6 |
7 | for (int index = 0; index < files.Count; index ++)
8 |
9 | {
10 |
11 | HttpPostedFile uploadfile = files[index];
12 |
13 | // You must create “upload” sub folder under the wwwroot.
14 |
15 | uploadfile.SaveAs(Server.MapPath(".") + "\\upload\\" + uploadfile.FileName);
16 |
17 | }
18 |
19 | HttpContext.Current.Response.Write("Upload successfully!");
20 |
21 | %>
--------------------------------------------------------------------------------
/php/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Take or select photo(s) and upload
8 |
9 |
112 |
113 |
114 |
115 |
116 |
117 |
138 |
139 |
140 |
141 |
--------------------------------------------------------------------------------
/php/savetofile.php:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------