// *** GET: All Posts *** public ActionResult Index() { ViewBag.Posts = "Posts"; PostsDBHandler PHandler = new PostsDBHandler(); ModelState.Clear(); return(View(PHandler.GetPostItem())); }
public ActionResult Details(int id) { PostsDBHandler PHandler = new PostsDBHandler(); return(View(PHandler.GetPostItem().Find(itemmodel => itemmodel.Id == id))); }