Modified validation method for better checking for html in form content