PDA

View Full Version : jscript to show month / year to comply with Firefox Mozilla


Ron Wolpa
05-10-2006, 03:34 AM
may 10th 2006



Ive employed the script at the bottom of this page to show month/year ;
It works fine with IE , Opera and Netscape if "Display like IE" menu is selected ;
is there a way to modify this script to render it compatible with Firefox or even another script that
works with all main browsers ?




<script type="text/javascript">
//<![CDATA[
var n = new Date(), m = ['Jan', 'Feb', 'March', 'April', 'May', 'June', 'July', 'August', 'September',
'October', 'November', 'December'];
document.write(m[n.getMonth()] + ' ' + n.getFullYear());
//]]>
</script>