<?php
include_once("include/config.php");
include_once("include/auth.lib.php");
list($status, $user) = auth_get_status();
if($status == AUTH_LOGGED & auth_get_option("TRANSICTION METHOD") == AUTH_USE_LINK){
$link = "?uid=".$_GET['uid'];
}else $link = '';
if (isset($_POST['e-postmain']))
{
while(list($key, $val) = each($_POST["delete"]))
{
if($val == 'del')
$deleteIds[] = $key;
$delmail = "DELETE FROM socio WHERE id='$key'";
$delres = mysql_query($delmail) or die("Query 1 failed");
$query2 = "UPDATE utenti SET credito =(credito + 1) WHERE username = '".$user["username"]."'";
$postdb2 = mysql_query($query2) or die ("Errore nel database");
}
header("Refresh: 2;URL=lista.php");
}
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Database Rivs</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link href="style.css" rel="stylesheet" type="text/css">
</head>
<body>
<table class="table1">
<!--DWLayoutTable-->
<tr>
<td height="20" colspan="9"><div align="center">Database ACSI Comitato Provinciale di Padova</div></td>
</tr>
<tr>
<td height="20"></td>
</tr>
<tr>
<td height="20" colspan="9"><div align="center"><?php include('in.php'); ?></div></td>
</tr>
</table>
<p></p>
<table class="table2">
<!--DWLayoutTable-->
<tr >
<td height="28" colspan="2" valign="top"><!--DWLayoutEmptyCell--> </td>
<td colspan="2" valign="top" class='form'><p align="center">I soci selezionati sono stati eliminati</p>
<p align="center">Il tuo credito è stato ripristinato </p></td>
<td width="224" valign="top"><!--DWLayoutEmptyCell--> </td>
</tr>
<tr >
<td height="24" colspan="5" valign="top"><!--DWLayoutEmptyCell--> </td>
</tr>
</table>
</body>
</html>