$date = new DateTime(); //this returns the current date time $result = $date->format('Y-m-d-H-i-s'); echo $result . "<br>"; $krr = explode('-', ... ... <看更多>
Since the Time class extends DateTime, if there are features that you need that this ... This can be any string that PHP's strtotime function can parse:. ... <看更多>