A system that registers curricula, the curriculum is active for months after the registration date, which in my table is the variable $ row_curriculos ['created'];
I was able to create the php that says the date that ends the registration.
<?php
$data = $row_curriculos['created'];
$timestamp = strtotime($data . "+6 months");
echo date('d/m/Y', $timestamp);
?>
Gostaria de exibir o numero de dias, exemplo:
Faltam XX dias para o cadastro expirar.
Tentei fazer assim:
<?php
$data = $row_curriculos['created'];
$timestamp = strtotime($data . "+6 months");
$dia_hora_atual = strtotime(date("Y-m-d"));
$dia_hora_evento = strtotime(date($timestamp));
$diferenca = $dia_hora_evento - $dia_hora_atual;
$dias = ($diferenca / 86400);
echo "$dias dia(s)";
?>
But it's returning the days as -17336.