jQuery UI & Datepicker: Display month & year menus

This entry is part 11 of 14 in the series jQuery UI Datepicker

jQuery UI Datepicker – Display month & year menus

Show month and year dropdowns in place of the static month/year header to facilitate navigation through large timeframes.

Add the boolean changeMonth and changeYear options.

<!doctype html>
<html lang='en'>
    <meta charset='utf-8'>
    <title>jQuery UI Datepicker - Display month &amp; year menus</title>
    <link rel='stylesheet' href='//code.jquery.com/ui/1.10.4/themes/smoothness/jquery-ui.css'>
    <script src='//code.jquery.com/jquery-1.10.2.js'></script>
    <script src='//code.jquery.com/ui/1.10.4/jquery-ui.js'></script>
    <link rel='stylesheet' href='https://codecrawl.com/code/jqueryui/jqueryui_style.css'>
        $(function () {
                changeMonth: true,
                changeYear: true

<p>Date: <input type='text' id='datepicker'></p>

Try The Code Datepicker Widgets API Doc
Series Navigation<< jQuery UI & Datepicker: Localize calendar
jQuery UI & Datepicker: Trigger by icon >>