add custom attribute for file mime type validation #6

Manually merged
wanderer merged 6 commits from feature-custom-attr-validation into master 2021-01-26 15:24:09 +01:00
Showing only changes of commit 6f6ebaa6fa - Show all commits

View File

@ -12,22 +12,22 @@
}}
<div class="form-group">
<label asp-for="@Model.DataTarget"></label>
<input asp-for="@Model.DataTarget" class="form-control" id="inputCarousel" aria-describedby="css selector id of the image" placeholder="Data Target">
<input asp-for="@Model.DataTarget" class="form-control" aria-describedby="css selector id of the image" placeholder="Data Target">
<span asp-validation-for="@Model.DataTarget" class="text-danger"></span>
</div>
<div class="form-group">
<label asp-for="@Model.Image"></label>
<input id="file" asp-for="@Model.Image" accept="image/*" class="form-inline" id="inputCarousel" aria-describedby="the image">
<input id="file" asp-for="@Model.Image" accept="image/*" class="form-inline" aria-describedby="the image">
<span asp-validation-for="@Model.Image" class="text-danger"></span>
</div>
<div class="form-group">
<label asp-for="@Model.ImageAlt"></label>
<input asp-for="@Model.ImageAlt" class="form-control" id="inputCarousel" aria-describedby="image alt text" placeholder="Image alt">
<input asp-for="@Model.ImageAlt" class="form-control" aria-describedby="image alt text" placeholder="Image alt">
<span asp-validation-for="@Model.ImageAlt" class="text-danger"></span>
</div>
<div class="form-group">
<label asp-for="@Model.CarouselContent"></label>
<input asp-for="@Model.CarouselContent" class="form-control" id="inputCarousel" aria-describedby="image description" placeholder="Image description">
<input asp-for="@Model.CarouselContent" class="form-control" aria-describedby="image description" placeholder="Image description">
<span asp-validation-for="@Model.CarouselContent" class="text-danger"></span>
</div>
<button type="submit" class="btn btn-primary">Submit</button>