public ActionResult AddFederation(string nomFederation, int?Pays, string web) { string pays = Pays.ToString(); Federation federation = new Federation(); nomFederation = HttpUtility.HtmlEncode(nomFederation); web = HttpUtility.HtmlEncode(web); if (Pays != null && nomFederation != "" && web != "") { federation.AddFederation(nomFederation, pays, web); return(Redirect("Index")); } else { return(Redirect("Index?error=Tous les champs doivent être complétés")); } }