Here's what im trying to do
<?php
//get time from what user input on post
$time = $_POST['time'];
?>
<script type="text/javascript">
//convert time to utc
var convertedDate = dateFormat('<?php echo $time ?>', 'isoUtcDateTime');
</script>
<?php
$query = "INSERT INTO $table (url, time) VALUES ('$url', 'convertedDate');";
mysql_query($query);
?>
I know you can't just place convertedDate
in there like that, so what im asking is how would I go about doing the javascript equivalent of what i did with <?php echo $time ?>