File:JavaScript getYear Method Problem.png
JavaScript_getYear_Method_Problem.png (326 × 190 pixels, file size: 6 KB, MIME type: image/png)
![]() | This is a file from the Wikimedia Commons. Information from its description page there is shown below. Commons is a freely licensed media file repository. You can help. |
Summary
DescriptionJavaScript getYear Method Problem.png |
English: Webpage screenshots showing the JavaScript .getYear method problem. It depicts the so-called Year 2000 problem.
The results of the .getYear method are different with Internet Explorer 6-8 and the other modern browsers:
.getYear is now obsoleted, but supported for backward compatibility by all modern browsers. .getFullYear is not supported before IE6. With those that support it, the 4-digit full year is always returned. This method is currently recommended.
BTW, if you want to return a 2-digit year value (only for AD, 3, 203, 1803, 1903 and 2003 all return "03", that are the last two digits) in modern browsers, you may try: ("0"+dateObj.getFullYear().toString()).slice(-2);
References: |
||
Date | |||
Source | Own work | ||
Author | Tomchen1989 |
Licensing
![]() ![]() |
This file is made available under the Creative Commons CC0 1.0 Universal Public Domain Dedication. |
The person who associated a work with this deed has dedicated the work to the public domain by waiving all of their rights to the work worldwide under copyright law, including all related and neighboring rights, to the extent allowed by law. You can copy, modify, distribute and perform the work, even for commercial purposes, all without asking permission.
http://creativecommons.org/publicdomain/zero/1.0/deed.enCC0Creative Commons Zero, Public Domain Dedicationfalsefalse |
Captions
Items portrayed in this file
depicts
some value
2 May 2014
File history
Click on a date/time to view the file as it appeared at that time.
Date/Time | Thumbnail | Dimensions | User | Comment | |
---|---|---|---|---|---|
current | 19:29, 2 May 2014 | ![]() | 326 × 190 (6 KB) | wikimediacommons>Tomchen1989 | User created page with UploadWizard |
File usage
The following page uses this file:
Metadata
This file contains additional information, probably added from the digital camera or scanner used to create or digitize it.
If the file has been modified from its original state, some details may not fully reflect the modified file.
Horizontal resolution | 28.34 dpc |
---|---|
Vertical resolution | 28.34 dpc |
Software used | |
Date and time of digitizing |
|