Note: After saving, you have to bypass your browser's cache to see the changes. Google Chrome, Firefox, Microsoft Edge and Safari: Hold down the ⇧ Shift key and click the Reload toolbar button. For details and instructions about other browsers, see Wikipedia:Bypass your cache.
// This script adds an "CfDs Today" link to the top toolbar that gives the list of CfDs opened today, adapted from [[User:Lourdes/AfDstarted.js]]
 
$.when( mw.loader.using( ['mediawiki.util'] ), $.ready ).done( function() {
  function englishMonthName(month){
    switch(month)
    {
      case 0: return 'January';
      case 1: return 'February';
      case 2: return 'March';
      case 3: return 'April';
      case 4: return 'May';
      case 5: return 'June';
      case 6: return 'July';
      case 7: return 'August';
      case 8: return 'September';
      case 9: return 'October';
      case 10: return 'November';
      case 11: return 'December';
      default: return;
    }
  }
  var d = new Date();
  mw.util.addPortletLink(
    'p-personal',
    mw.util.getUrl('Wikipedia:Categories for discussion/Log/' + d.getUTCFullYear() + ' ' + englishMonthName(d.getUTCMonth()) + ' ' + d.getUTCDate()),
    'CfDs Today',
    'pt-specialnew',
    'View the CfD discussions that have been opened today',
    null,
    '#pt-preferences'
  );
});