Viewing file: useredit.php (3.96 KB) -rw-rw-rw- Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
/**
* UserEdit.php
*
* This page is for users to edit their account information
* such as their password, email address, etc. Their
* usernames can not be edited. When changing their
* password, they must first confirm their current password.
*
* Written by: Jpmaster77 a.k.a. The Grandmaster of C++ (GMC)
* Last Updated: August 26, 2004
*/
include("include/session.php");
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html class="noI firefox" xmlns="http://www.w3.org/1999/xhtml"><head>
<title>Editar Cuenta</title>
<!-- Meta Tags -->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<!-- CSS -->
<link rel="stylesheet" href="../css/dynamic.css" type="text/css">
<link rel="stylesheet" href="../css/creation.css" type="text/css">
</head><body id="creation">
<?php
/**
* User has submitted form without errors and user's
* account has been edited successfully.
*/
if(isset($_SESSION['useredit'])){
unset($_SESSION['useredit']);
echo "<h1>User Account Edit Success!</h1>";
echo "<p><b>$session->username</b>, tu cuenta ha sido actualizada satisfactoriamente. "
."<a href=\"../index.php\">Inicio</a>.</p>";
}
else{
?>
<?php
/**
* If user is not logged in, then do not display anything.
* If user is logged in, then display the form to edit
* account information, with the current email address
* already in the field.
*/
if($session->logged_in){
?>
<div id="container" class="clearfix">
<img src="../images/sidePlan1.png" alt="" name="sidePlan" width="201" height="479" id="sidePlan">
<div id="nav">
<h1 class="logo color1"><a title="Editar cuenta de Usuario">Wufoo</a></h1>
</div>
<?php
if($form->num_errors > 0){
echo "<td><font size=\"2\" color=\"#ff0000\">".$form->num_errors." errore(s) encontrados</font></td>";
}
?>
<form id="payment" class="wufoo leftLabel plan1" action="process.php" method="post">
<ul class="fundamentals">
<li class="first section">
<h3>Editar Cuenta: <?php echo $session->username; ?>!</h3>
<div></div>
</li>
<li class="complex">
<label class="desc" for="email"> Password Actual <span class="req">*</span> <span class="req"></span>
<strong>Digita el password actual .</strong></label>
<div>
<span class="left">
<input name="curpass" type="password" class="field text addr" id="password" maxlength="32" value="<?php echo $form->value("curpass"); ?>">
<label>Maximo <b>32</b> caracteres de largo.<?php echo $form->error("curpass"); ?></label>
</span></div>
</li>
<li class="complex">
<label class="desc" for="password">
Password Nuevo <span class="req">*</span>
<strong>Digita el password nuevo.</strong></label>
<div>
<span class="left">
<input name="newpass" type="password" class="field text addr" id="password" maxlength="32" value="<?php echo $form->value("newpass"); ?>">
<label>Maximo <b>32</b> caracteres de largo. <?php echo $form->error("newpass"); ?></label>
</span></div>
</li>
<li class="">
<label class="desc" for="wufooName">
Em@il <span class="req">*</span><strong>Digita el correo.</strong></label>
<div>
<input id="wufooName" name="email" class="field text full" type="text" maxlength="50" value="<?php
if($form->value("email") == ""){
echo $session->userinfo['email'];
}else{
echo $form->value("email");
}
?>">
<label id="domain">ejemplo: <b class="color1">juan.tribin</b>@secretariadeambiente.gov.co <?php echo $form->error("email"); ?></label>
</div>
</li>
<li class="buttons">
<div>
<input type="submit" value="Editar Cuenta">
<a href="../index.php">Cancel</a></div>
<input type="hidden" name="subedit" value="1">
</li>
</ul>
<!--paymentSummary-->
</form>
<?php
}
}
?>
<div class="footer">
<i class="c1">·</i>
Copyright © 2010
<i class="c1">·</i><strong>Secretaria de Ambiente </strong><b>.</b>
<i class="c1">·</i>Todos los derechos reservados <i class="c1">·</i></div>
</div><!--container-->
</body></html>
|