Question: I have the following javascript code 

```
date.getMonth());

```

This returns me the name of the month in English, how can I get the languages in Italian or in an another language. What does the language option depend on? I mean, what determines the language of the returned variable, and how can I change this language? 

My full code is as follows; 

```
var currentTime = new Date() 
var minDate = new Date(currentTime.getYear(), currentTime.getMonth()-1); 
var maxDate =  new Date(currentTime.getFullYear(), currentTime.getMonth());

```

Answer: 
The getMonth() method returns the month (from 0 to 11) for the specified date, according to local time.

then create a month array as per required language..

Try this:-

```
<html>
<body>

<p id="demo">Click the button to display the name of this month.</p>

<button onclick="myFunction()">Try it</button>

<script>
function myFunction()
{
var month=new Array();
month[0]="January";
month[1]="February";
month[2]="March";
month[3]="April";
month[4]="May";
month[5]="June";
month[6]="July";
month[7]="August";
month[8]="September";
month[9]="October";
month[10]="November";
month[11]="December";

var d = new Date();
var x = document.getElementById("demo");
x.innerHTML=month[d.getMonth()];
}
</script>

</body>
</html>

```

Hope this will help you..
Date.getMonth() does not return the name of the month, it returns an integer 0..11 representing January..December

If you want the name of the month in your locale language, then see this SO question and the different answers [Get month name from Date](https://stackoverflow.com/questions/1643320/get-month-name-from-date-using-javascript)

I find this particular answer <https://stackoverflow.com/a/16089495/30447> specially useful for your case.