Answer the question
In order to leave comments, you need to log in
Why doesn't it go to Post request in section?
On the page where the date picker is needed, I insert the bootstrap datepicker, it works. But as soon as I place it in the section it doesn't go to the post request. Why?
@section SelectDate {
@using (Html.BeginForm("GetList", "Home", new { IsPlan = (bool)ViewBag.IsPlan }))
{
<form class="form-inline" role="form">
<div class="form-group">
<div class='input-group date' id='datetimepicker'>
<input type='text' class="form-control" name="date" value="Выберите дату" />
<span class="input-group-addon">
<span class="glyphicon glyphicon-calendar"></span>
</span>
</div>
</div>
<button type="submit" class="btn btn-default">Ок</button>
</form>
}
}
<div class="navbar-form navbar-left" >
@RenderSection("selectDate", false)
</div>
Answer the question
In order to leave comments, you need to log in
And what actually happens? What is rendered to the client? Are there any errors in the browser console? Bootstrap is a client framework, Razor is a server framework. They don't care about each other, they shouldn't depend on each other.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question