Tuesday, June 11, 2019

Allow Html

1. Allow html > by default this is disabled in mvc, if i want to pass html tag in string, we have to                 AllowHtml attribute

       [AllowHtml]
       Public string Detail { get; set; }

2. Allow Html On Action Method :- addding filter   [ValidateInput(false)]

      [HttpPost]
      [ValidateInput(false)]
      public ActionResult Create(Employee emp)
     {
           return View()
     }



No comments:

Post a Comment

Linq Expression syntax for where condtion in linq

(Expression<Func<T, bool>> filter)