Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.javascript > #19427

Re: About format to always use 2 digits for hour

Path csiph.com!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!newsfeed.fsmpi.rwth-aachen.de!news-1.dfn.de!news.dfn.de!news.informatik.hu-berlin.de!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail
From "Mel Smith" <med_cutout_syntel@aol.com>
Newsgroups comp.lang.javascript
Subject Re: About format to always use 2 digits for hour
Date Tue, 23 Apr 2013 12:40:13 -0600
Lines 18
Message-ID <ato2sjFlcf5U1@mid.individual.net> (permalink)
References <kl60sb$9nn$1@dont-email.me> <XnsA1ABB47255529eejj99@194.109.133.133>
X-Trace individual.net kSWHSZpIbLw+IHghkTgZ3gIdW9azUqji3zqk5q+KD1m0NKEOjY
Cancel-Lock sha1:qtwuV5tJLexvYIe00uyTTLQlJo0=
X-Priority 3
X-MSMail-Priority Normal
X-Newsreader Microsoft Outlook Express 6.00.2900.5931
X-RFC2646 Format=Flowed; Original
X-MimeOLE Produced By Microsoft MimeOLE V6.00.2900.6157
Xref csiph.com comp.lang.javascript:19427

Show key headers only | View raw


Evertjan said:

> Make your own function:
>
> function two(x){
>  return ('0' + x).substr(-2);
> };
>

Hi Evertjan:

    The function above on IE8 fails:    '10' is returned as '010'

    IE10, Chrome, and FF work properly..

-Mel Smith

Back to comp.lang.javascript | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

About format to always use 2 digits for hour "Tony" <tony.johansson@inport.com> - 2013-04-23 15:07 +0200
  Re: About format to always use 2 digits for hour JJ <duh@nah.meh> - 2013-04-23 20:55 +0700
  Re: About format to always use 2 digits for hour "Jukka K. Korpela" <jkorpela@cs.tut.fi> - 2013-04-23 16:58 +0300
  Re: About format to always use 2 digits for hour "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2013-04-23 17:44 +0200
    Re: About format to always use 2 digits for hour "Mel Smith" <med_cutout_syntel@aol.com> - 2013-04-23 12:40 -0600
      Re: About format to always use 2 digits for hour Christoph Becker <cmbecker69@gmx.de> - 2013-04-23 21:02 +0200
    Re: About format to always use 2 digits for hour Dr J R Stockton <reply1300@merlyn.demon.co.uk.invalid> - 2013-04-24 22:12 +0100
      Re: About format to always use 2 digits for hour "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2013-04-25 09:39 +0200
        Re: About format to always use 2 digits for hour Dr J R Stockton <reply1300@merlyn.demon.co.uk.invalid> - 2013-04-26 20:56 +0100
          Re: About format to always use 2 digits for hour "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2013-04-27 10:50 +0200
            Re: About format to always use 2 digits for hour Dr J R Stockton <reply1300@merlyn.demon.co.uk.invalid> - 2013-04-28 16:49 +0100
              Re: About format to always use 2 digits for hour Stefan Weiss <krewecherl@gmail.com> - 2013-04-29 01:19 +0200
              Re: About format to always use 2 digits for hour "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2013-04-29 09:05 +0200
                Re: About format to always use 2 digits for hour Dr J R Stockton <reply1300@merlyn.demon.co.uk.invalid> - 2013-04-30 22:14 +0100

csiph-web