Размер файла: 2.08Kb
<?php
/*-----------------------------------------------------------------------------------------
mcGalleryPRO
All code is © 2003 Marc Cagninacci.
No files may be redistributed in whole or significant part.
----------------- mcgalleryPRO IS NOT FREE SOFTWARE -------------------
You should have receive a file called license.txt in this package
--------------------------------------------------------------------------------------------*/
echo '<form method="post" name="passform" action="index.php">';
echo '<table border="0" cellspacing="1" cellpadding="2" width="300" class="td1">';
echo '<tr><td class="td0" align="center"><font size="2">'.ucwords($l_changepass1).'</font></td></tr>';
if ($newpass != $newpass2 || empty($newpass) || strlen($newpass) < 6 )
{
if ($newpass != $newpass2)
{
echo '<tr><td class="td2" align="center"><font size="2"><b>'.$l_changepass4.'</b></font></td></tr>';
}
if (strlen($newpass) < 6 && !empty($newpass))
{
echo '<tr><td class="td2" align="center"><font size="2"><b>'.$l_changepass4.'</b></font></td></tr>';
}
echo '<tr><td class="td2" align="right"><font size="2">'.$l_changepass2.'</font> <input type="password" name ="newpass" size="10"> </td></tr>';
echo '<tr><td class="td2" align="right"><font size="2">'.$l_changepass3.'</font> <input type="password" name ="newpass2" size="10"> </td></tr>';
echo '<tr><td class="td1" align="center"><input type="hidden" name="cp" value="1"><input type="submit" value="OK" name="valid"></td></tr>';
}
if ($newpass == $newpass2 && !empty($newpass) && strlen($newpass) >= 6)
{
echo '<tr><td class="td2" align="center"><font size="2"><b>'.$l_changepass5.', '.$private_login.'.<br>'.$l_changepass6.'</b></font></td></tr>';
$query = "UPDATE mcgallery_members SET password = '$newpass' WHERE login = '$private_login'";
mysql_query($query);
$_SESSION['private_pass'] = $newpass;
}
echo '<tr><td class="td0"> </td></tr>';
echo '</table></form>';
?>
<script language="JavaScript">
<!--
document.passform.newpass.focus()
// -->
</script>