Complete list of custom icon properties for Bootstrap 3 Datepicker

Complete list of custom icon properties for Bootstrap 3 Datepicker

If you are using Bootstrap 3 Datepicker and want to change the icons used for the symbols within the datepicker then you can.

On initialisation you can add an icons property and specify each icon you want.

You knew this because like a good developer you read the documentation.

What the documentation doesn’t tell you is the names you need to use for them all.

Through trial and error (and looking at the source code) I was able to grab them all.

  $('.my-date-picker').datetimepicker({
    icons: {
      time: "fa fa-clock-o",
      date: "fa fa-calendar",
      up: "fa fa-caret-up",
      down: "fa fa-caret-down",
      previous: "fa fa-caret-left",
      next: "fa fa-caret-right",
      today: "fa fa-today",
      clear: "fa fa-clear",
      close: "fa fa-close"
    }
  });

I hope this saves someone the 30 minute search I had to go on!

Recent posts View all

SEO

Google follows URLs in text

Today I learned that Google follows URLs even when they are plain text

Web Dev

Check in with your database

It pays to take a step back and look at how your database is set up every so often. You will often find quick wins and hidden tech debt.