[AcceptVerbs(HttpVerbs.Get)] public ActionResult PersonalProfile() { return View(); } [AcceptVerbs(HttpVerbs.Post)] public ActionResult PersonalProfile( string photo_filename) { if (Request.Files["photo"] != null) // If uploaded synchronously { photo_filename = _fileStore.SaveUploadedFile(Request.Files["photo"]); } // ViewData["photo_guid"] = photo_guid.Value; ViewData["photo_filename"] = photo_filename; return View("Completed"); }
</head> <body> <div id="MainContents"> <h1>Thanks</h1> We have stored your photo <b><%= ViewData["photo_filename"]%></b> <br /> <img src="" alt="" /> //image to be displayed </div> </body>
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)