コード例 #1
0
        public ActionResult Preview(SendWidgetModel sendWidgetModel)
        {
            var json = new JavaScriptSerializer().Serialize(sendWidgetModel);

            Session["widget"] = json;
            return(RedirectToAction("Sent"));
        }
コード例 #2
0
 public ActionResult MvcJson(SendWidgetModel sendWidgetModel)
 {
     return(Json(string.Format("Sent {0} to {1}", sendWidgetModel.widgetMessage, sendWidgetModel.toEmail), JsonRequestBehavior.DenyGet));
 }