[Resolvido] Inserir data e hora atual
Pessoal,
Estou tentando inserir a data com horario em uam tabela e não estou conseguindo.
Na tabela o campo é datetime
Segue os comandos
<?php include('../config.php'); ?>
<?php
$codigo = $_REQUEST["codigo"];
$evento = $_REQUEST["evento"];
$data = timestamp('Y-m-d H:i:s');
$sql = "INSERT INTO registro_ponto (codigo,data,evento) VALUES ('$codigo', '$data','$evento')";
mysql_query($sql, $conexao) or die (mysql_error());
header("Location: ./registro_ponto.php");
exit;
?>
Já tentei varias opção se sucesso...
Segue erro
Fatal error: Call to undefined function timestamp() in C:\AppServ\www\w_ponto\registro_ponto\salvar.php on line 5
Discussão (9)
Carregando comentários...