<?php $fecha = date('Y-m-d H:i:s'); $H = strtotime($fecha)*1000; echo 'H = new Date(' . $H . ');'; ?>