SORU
1 NİSAN 2011, Cuma


Javascript Dün

Nasıl hesaplayabilirim 'dün gün' JavaScript?

CEVAP
1 NİSAN 2011, Cuma


var date = new Date();

date ; //# => Fri Apr 01 2011 11:14:50 GMT 0200 (CEST)

date.setDate(date.getDate() - 1);

date ; //# => Thu Mar 31 2011 11:14:50 GMT 0200 (CEST)

Bunu Paylaş:
  • Google+
  • E-Posta
Etiketler:

YORUMLAR

SPONSOR VİDEO

Rastgele Yazarlar

  • Barnacules Nerdgasm

    Barnacules N

    20 Temmuz 2006
  • NLthomas21

    NLthomas21

    20 Mayıs 2008
  • Sergio Lafuente Rubio

    Sergio Lafue

    11 Aralık 2008