How to create a multilingual contact form with a custom data model ?
Hello la team,
I want to create a multilingual contact form with a custom data model. I relied on the following example from the Umbraco documentation :
sample umbraco v8
but my website is multi language and I would like to retrieve the property values in the template of my contact page and I encounter difficulties ...
When i use @inherits Umbraco.Web.Mvc.UmbracoViewPage
How to create a multilingual contact form with a custom data model ?
Hello la team, I want to create a multilingual contact form with a custom data model. I relied on the following example from the Umbraco documentation : sample umbraco v8
but my website is multi language and I would like to retrieve the property values in the template of my contact page and I encounter difficulties ...
When i use @inherits Umbraco.Web.Mvc.UmbracoViewPage
i have an error because already model
My partial view :
@using (Html.BeginUmbracoForm("Submit", "ContactForm")) { @Html.AntiForgeryToken()
My Model :
using System.Collections.Generic; using System.ComponentModel.DataAnnotations; using System.Linq; using System.Web;
namespace WebSite.Models { public class ContactFormViewModel { [Required] [DataType(DataType.Text)] public string Nom { get; set; } [Required] [DataType(DataType.Text)] public string Prenom { get; set; } [Required] [DataType(DataType.PhoneNumber)] public string Telephone { get; set; } [Required] [DataType(DataType.EmailAddress)] public string Email { get; set; } [Required] [DataType(DataType.Text)] public string ObjetDemande { get; set; } [Required] [DataType(DataType.Text)] public string Message { get; set; } public bool ContactParMail { get; set; } public bool ContactParTelephone { get; set; } public bool RecevoirInformations { get; set; }
}
Do you have a sample with multi-cultures contact form?
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.