IPB

Bienvenue invité ( Connexion | Inscription )

 
Reply to this topicStart new topicStart Poll

En ligne · [ Standard ] · Linéaire+

> date en PHP ?

joez
post 21/05/2002 9:38
Message #1


Gnome
**

Groupe : Membres
Messages : 48
Inscrit le : 16/05/2002 23:00
Lieu : .gif
Membre no. 6



qq a un script pour retrouver en PHP une date systeme a partir d'uen date du type 21-05-02 ?

thx


--------------------
@++JoezBZH Power
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Darhf
post 21/05/2002 10:38
Message #2


Goule
****

Groupe : Membres
Messages : 828
Inscrit le : 17/05/2002 23:00
Lieu : Toulouse.gif
Membre no. 38



J'ai fait ça pour mon forum, ça convertit un datetime mysql en timestamp :

CODE

function nix_date($entry){
list($fulldate,$time)=explode(" ",$entry);
list($year,$month,$day)=explode("-",$fulldate);
list($hour,$minute,$second)=explode(":",$time);
$ret=mktime($hour,$minute,$second,$month,$day,$year);
return $ret;
}


wala smile.gif


--------------------
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Kinou
post 15/06/2002 20:58
Message #3


Schtroumpf
*

Groupe : Membres
Messages : 4
Inscrit le : 14/06/2002 23:00
Membre no. 70



oula lol

mktime() va etre plus simple wink.gif
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Darhf
post 16/06/2002 21:59
Message #4


Goule
****

Groupe : Membres
Messages : 828
Inscrit le : 17/05/2002 23:00
Lieu : Toulouse.gif
Membre no. 38



Ben il y est le mktime() !


--------------------
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Kinou
post 17/06/2002 10:26
Message #5


Schtroumpf
*

Groupe : Membres
Messages : 4
Inscrit le : 14/06/2002 23:00
Membre no. 70



arf j'avais pas fait gaffe

autant pr moi smile.gif
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

Reply to this topicTopic OptionsStart new topic
2 utilisateur(s) sur ce sujet (2 invité(s) et 0 utilisateur(s) anonyme(s))
0 membre(s) :
 

Version bas débit Nous sommes le : : 27/04/2024 13:04