Thread ID: |
Created: |
Updated: |
Platform: |
Replies: |
148626 | Oct 28,2019 01:08 PM UTC | Nov 1,2019 06:37 PM UTC | ASP.NET MVC - EJ 2 | 4 |
![]() |
Tags: RichTextEditor |
// POST: Mails/Edit/5
// To protect from overposting attacks, please enable the specific properties you want to bind to, for
// more details see https://go.microsoft.com/fwlink/?LinkId=317598.
[HttpPost]
[ValidateAntiForgeryToken]
[ValidateInput(false)] // Allowing html content access from form fields
public ActionResult Edit([Bind(Include = "Id,Content")] Mail mail, FormCollection formCollection)
{
string rteValue0 = formCollection["rte120"];
string rteValue1 = formCollection["rte121"];
string rteValue2 = formCollection["rte122"];
string rteValue3 = formCollection["rte123"];
string rteValue4 = formCollection["rte124"];
if (ModelState.IsValid)
{
db.Entry(mail).State = EntityState.Modified;
db.SaveChanges();
return RedirectToAction("Index");
}
return View(mail);
}
|
This post will be permanently deleted. Are you sure you want to continue?
Sorry, An error occured while processing your request. Please try again later.
This page will automatically be redirected to the sign-in page in 10 seconds.