5

Can anyone help me uppercase the first letter of the month in fullcalendar? When I write the fullcalendar, I found that the in English, for example August, the display of month in title is correctly "August" or "Aug.". But in Spanish the first letter of the month is not capitalized. For example, "Agosto" and "Ago." is "agosto" and "ago.".

Is there any way to correct this using css or the only way is to change the locale_all.js file?

situation for the moment AgendaWeek view situation for the moment month view

Adeel
  • 2,901
  • 7
  • 24
  • 34
Minalinsky
  • 277
  • 6
  • 16
  • 5
    CSS : `text-transform: capitalize;` ? – l2aelba Aug 22 '17 at 14:07
  • @l2aelba: emm, i have already tried this one. With this css, i got AGOSTO 2017, but what my client need is Agosto 2017 -0-, this is the probleme – Minalinsky Aug 22 '17 at 14:19
  • This will help https://stackoverflow.com/questions/5577364/make-the-first-character-uppercase-in-css – Sanchit Patiyal Aug 22 '17 at 14:31
  • @SanchitPatiyal: Thank you for the resource. But i have already tried this one-0-, that doesn't work for me although i don't know why. – Minalinsky Aug 22 '17 at 14:38
  • `capitalize` should only transforms the first character of each word to uppercase. @l2aelba 's solution should work. You can check and try [all CSS text-transform properties here](https://www.w3schools.com/cssref/pr_text_text-transform.asp). – brian17han Aug 22 '17 at 15:07
  • @brian17han: thank you, i'll check it – Minalinsky Aug 22 '17 at 15:52
  • I don't know Spanish culture but perhaps, if that's the way it's formatted in the Spanish locale file, it's because that's the way Spanish speakers would expect it to appear? Just a thought, worth checking. – ADyson Aug 23 '17 at 08:41
  • @I2aelba: emm,sry, today i retried your response and it works now for me =-=, but there is another one who give an answer as yours, can you give your answer as answer and i can accept it? – Minalinsky Aug 24 '17 at 11:27

1 Answers1

9

By using CSS, you can easily capitalize the first alphabet of the title (month).

please use this .fc-toolbar { text-transform: capitalize; }

or you can also check the link First capital spanish letter

Adeel
  • 2,901
  • 7
  • 24
  • 34
  • Thank you, this works, but there is already another one who gives the same answer so i can't give you a check. Sorry – Minalinsky Aug 24 '17 at 11:28
  • It doesn't matter, I was just helping you out because you were struggling with the issue and nobody said that you have to place this `text-tranform: capitalize` on the `.fc-toolbar` class which is a fullcalendar class – Adeel Aug 24 '17 at 17:34