Como Alterar Senha Depois De Logado Com PHP
Eae Pessoal, Estou Criando Um Site E Ja Fiz Um Sistema De Cadastro, Login e
Ja Criei A Pagina Inicial Do Meu Site Mas, Quero Fazer Uma Pagina De alteração
De Senha Do User Após Ser Logado. Ja Fiz O Form Em Html Ficou ASSIM:
----------------------------------------------------------------------------------------------------------
<?php
session_start();
if(!isset($_SESSION["email"]) || !isset($_SESSION["senha"])) {
header("Location: ../Cadastro/login.php");
exit;
}
?>
<?php
$servidor = "mysql.hostinger.com.br";
$usuario = "u745788626_admin";
$senha = "114233";
$banco = "u745788626_web";
$conexao = mysql_connect($servidor,$usuario,$senha) or die(mysql_error());
mysql_select_db($banco) or die(mysql_error()); ?>
<?php
session_start();
?>
<!DOCTYPE html>
<!--[if IEMobile 7 ]> <html class="no-js iem7"> <![endif]-->
<!--[if (gt IEMobile 7)|!(IEMobile)]><!--> <html class="no-js" lang="pt-br" xml:lang="pt-br" xmlns="[http://www.w3.org/1999/xhtml](http://www.w3.org/1999/xhtml)" xmlns:fb="http://www.facebook.com/2008/fbml" itemscope [itemtype="http://schema.org/Article"](itemtype=) prefix="og: [http://ogp.me/ns#](http://ogp.me/ns#) fb: [http://ogp.me/ns/fb#">](http://ogp.me/ns/fb#) <!--<![endif]-->
<head>
<title>Alterar Senha</title>
<meta name='description' content='Website Sobre Informática.' />
<meta name="viewport" content="initial-scale=1.0, width=device-width, maximum-scale=1.0, user-scalable=no" />
<meta http-equiv='Content-Type' content='text/html; charset=utf-8' />
<meta name="verify-v1" content="7cbL0pDFrGAjwDosngmCT0io1yg8zgz52KKk8VLuWgA=" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="author" content="Paulo Henrique Menezes Da Silva" />
<meta name="robots" content="all" />
<meta name="ICBM" content="-22.976781,-43.193082" />
<meta property="fb:admins" content="100003747649444" />
<link rel="shortcut icon" href="/img/icon.ico" />
<link rel='stylesheet' type='text/css' href='../CSS/style.css' />
<link rel='stylesheet' type='text/css' href='../CSS/style2.css' />
<body>
<div id="header">
<header>
<div id="view-port">
<center>
<form method="post" action="Alterar.php">
<b><br>
<center> <font color="black">
<span>Sua Senha Atual:<br /> <?php echo $_SESSION['senha'];
?></span>
<br /><br /><br />
<label>Nova Senha:</label><input type="password" name="email" size=20 />
<br>
</center>
<br />
<input type="submit" value="Alterar Senha" />
</font></b></form>
<hr color="#000000" size="5px"><br />
</form>
</center>
</div></div>
<div class="irtopo"><a href="#header">Topo</a></div>
</header>
</body>
</html>
----------------------------------------------------------------------------------------------------------
E O Código PHP Eu Não Consegui Criar Ainda Pois Sou iniciante Em PHP e
mysql...
Alguem Tem O Script PHP Para Fazer Isto? Se Tiver Brigado...
Discussão (2)
Carregando comentários...