Almanacco del Calcio Toscano

Formazione eliminata

[source]
<?php
require_once ‘fanta/utentej.php’;
if($usr_id == 0){
header(‘Location: https://vibrant-bhaskara.185-216-75-167.plesk.page/index.php?option=com_content&view=article&id=81’);
}
require_once ‘fanta/database.php’;
$elim = $_POST[‘delete’];
$id_giorn = $_POST[‘id_giorna’];
$dat_giorn = $_POST[‘giorna’];

//echo $elim, $id_giorn, $dat_giorn;

if($elim == “elimina”)
{
$elimina= “DELETE
FROM squadra
WHERE (id_giornata = $id_giorn) AND (id_user = $usr_id)”;

$cancellata = mysql_query($elimina);

$controllo=”SELECT
*
FROM squadra
WHERE (id_giornata = $id_giorn) AND (id_user = $usr_id)”;

$verifica = mysql_query($controllo);

if (mysql_num_rows($verifica) == 0):
header(‘Location: https://vibrant-bhaskara.185-216-75-167.plesk.page/index.php?option=com_content&view=article&id=93’);

exit;
endif;

//echo “cancellata”;
//echo $elim, $id_giorn, $dat_giorn;
}

else {
echo “Non sono stati cancellati i dati, riprova”;
echo ‘<a class=”btn btn-primary” href=”https://vibrant-bhaskara.185-216-75-167.plesk.page/index.php?option=com_content&amp;view=article&amp;id=91″ role=”button”>Inserisci Formazione</a></div>’;
}
//echo $elim, $id_giorn, $dat_giorn;
?>

[/source]