Sephy Posted June 19, 2008 Report Posted June 19, 2008 Tatad gribetos saglabat datumu kad lietotajs ir registrejies tapec uztaisiju date lauku tabulaa! Ir kads jau gatavs skripts kas automatiski panem teiksim laiku no sistēmas un ieraxta kad lietotajs reģistrējies?!
andrisp Posted June 19, 2008 Report Posted June 19, 2008 INSERT INTO users (name, pass, ..., date) VALUES ('janka', '3fd33d....', ..., NOW())
Sephy Posted June 19, 2008 Author Report Posted June 19, 2008 (edited) NOW() tiehsi tas kas vajadzigs paldies! edit:datums nepievienoja ;[ <?php $insert = "INSERT INTO news (newsname,newstext,createnew) VALUES ('".$_POST['title']."', '".$_POST['add']."', '"NOW()"')"; $add_member = mysql_query($insert); ?> Edited June 19, 2008 by Sephy
Paulinjsh Posted June 19, 2008 Report Posted June 19, 2008 vispār jau vajadzētu manuprāt ne tikai datumu (date) glabāt, bet gan datums + laiks (datetime).
andrisp Posted June 19, 2008 Report Posted June 19, 2008 Un NOW() ir funkcija. Tā nav jāliek pēdiņās.
Recommended Posts