@manhng

Welcome to my blog!

Bootstrap Datetimepicker

March 16, 2018 00:28

Bootstrap Datetimepicker 4 (edit)

https://stackoverflow.com/questions/40035730/bootstrap-date-time-picker

https://stackoverflow.com/questions/23137720/disable-time-in-bootstrap-date-time-picker

https://stackoverflow.com/questions/40035730/bootstrap-date-time-picker

https://stackoverflow.com/questions/23137720/disable-time-in-bootstrap-date-time-picker

https://stackoverflow.com/questions/35778600/bootstrap-datepicker-locale-with-momentjs

https://stackoverflow.com/questions/33918017/bootstrap-datepicker-how-to-use-specific-time-zone

Bootstrap Datetimepicker 3

http://www.skimedic.com/blog/post/2015/04/03/Using-a-DateTime-Picker-for-ASPNET-MVC-5-with-Bootstrap.aspx

http://eonasdan.github.io/bootstrap-datetimepicker/#options

https://stackoverflow.com/questions/40035730/bootstrap-date-time-picker

https://stackoverflow.com/questions/24410685/bootstrap-3-datetimepicker-3-0-0-week-starts-at-monday

https://stackoverflow.com/questions/19382189/change-language-for-bootstrap-datetimepicker

https://stackoverflow.com/questions/22846525/bootstrap-datetimepicker-not-working

Instead of using moment.js I used moment-with-langs.js (I guess it came with default package ASP.NET MVC 5).

By calling:

<script type="text/javascript">
    $('#DateTime').datetimepicker({
        language: "hr"
    });
</script>

thing works, finally the calender starts from monday.

UPDATE: Even better, add key to web.config

<appSettings>    
    <add key="Culture" value="hr" />
</appSettings>

and then

$(document).ready(function () {
    $(document).on('focus', '#Date', function () {
        $(this).datetimepicker({
            locale: '@System.Configuration.ConfigurationManager.AppSettings["Culture"]',
            format: 'DD:MM:YYYY',
        });
    });
});

mvc5

October 5, 2017 10:04

ASP.NET MVC 5 (edit)

Phân quyền trong MVC 5

https://www.youtube.com/watch?v=qyqGbDet8GI

DropDownLists in MVC 5

https://nimblegecko.com/using-simple-drop-down-lists-in-ASP-NET-MVC/

https://nimblegecko.com/how-to-set-default-selected-value-on-drop-down-list-from-database/

Error page in MVC 5

http://techfunda.com/howto/260/redirecting-to-default-error-page-from-controller-action

http://benfoster.io/blog/aspnet-mvc-custom-error-pages

Multiple Submit Buttons in MVC 5

https://www.pluralsight.com/guides/asp-net-mvc-using-multiple-submit-buttons-with-default-model-binding-and-controller-actions

Categories

Recent posts