0
我使用TinyMCE为用户提供了HTML标签,因此我将它们存储在数据库中,并稍后在页面的相应部分调用它们。如何使用插件实体框架模型更新数据库?
一切正常工作,直到我点击更新按钮,它告诉我更新成功,但我发现它发回相同的旧数据。
这是更新语法我用
int ID1 = int.Parse(Request.QueryString["titelid"]);
webmarketingEntities wme = new webmarketingEntities();
articls ar = new articls();
articls query = (from art in wme.articls
where art.id==ID1
select art).First();
ar.articalcontent = txtconteny.Text;
ar.pagedescription = txtdescription.Text;
ar.pagetitle = txttitle.Text;
wme.SaveChanges();