~ POST ~
if (isset($userid) && !$_GET['nt']) { ?> } ?>
session_start(); if (isset($_COOKIE['idutente'])) { $_SESSION['user'] = $_COOKIE['idutente']; } if (isset($_SESSION['user'])) { require_once ("../config/config.php"); $sql="SELECT * FROM ".$database.".profile WHERE user_code='".$_SESSION['user']."'"; $query=@mysql_query($sql) or die (mysql_error()); $rowp = mysql_fetch_array($query) or die (mysql_error()); $num=mysql_num_rows($query); if ($num==1) { $userid = $rowp['user_id']; $usercode = $rowp['user_code']; $name = html_entity_decode($rowp['name'], ENT_QUOTES, 'UTF-8'); $surname = html_entity_decode($rowp['surname'], ENT_QUOTES, 'UTF-8'); $username = $name." ".$surname; $mail = $rowp['mail']; $about = html_entity_decode($rowp['about_me'], ENT_QUOTES, 'UTF-8'); $cf = $rowp['cf']; $birthday = $rowp['birthday']; $gender = $rowp['gender']; $country = $rowp['country_id']; $address = $rowp['address']; $work = html_entity_decode($rowp['work'], ENT_QUOTES, 'UTF-8'); $phone = $rowp['phone']; $photo_profile = $rowp['photo_profile']; $photo_diary = $rowp['photo_diary']; $accesso = "ok"; if ($rowp['name'] == '' or $rowp['name'] == 'tuonome' or $rowp['surname'] == '' or $rowp['surname'] == 'tuocognome') { header("Location:../mail/register2.php"); } // preleviamo il dato necessario per sapere quale pagina caricare nel profilo $act = $_GET['act']; ?>
include ("../img/favicon/favicon.php"); ?> include ("../css/css.php"); ?> include ("../js/script.php"); ?>