Date.toGMTString() : toGMTString : Date JAVASCRIPT TUTORIALS


JAVASCRIPT TUTORIALS » Date » toGMTString »

 

Date.toGMTString()












Syntax








date.toGMTString()



The toGMTString() method returns a string representing the universal time of the Date object.

The date is converted to the GMT time zone before being converted to a string.

The format of the string will look similar to the following:








Mon, 24 Oct 1982 12:03:27 GMT














<html>
    <script language="JavaScript">
    <!--
    theDate = new Date();

    document.write(theDate.toGMTString());
    -->
    </script>
    </html>







HTML code for linking to this page:

Follow Navioo On Twitter

JAVASCRIPT TUTORIALS

 Navioo Date
» toGMTString