Example #1
0
    echo "<small>" . _T('info_more_than_three') . "</small><br />";
    echo "<input type='text' id='username' name='username' class='formo' value='" . _session('username') . "' size='40'></p>\n";
    echo "<small>" . _T('pass_info_password_by_mail') . "</small>\n";
    echo "</fieldset>\n";
    echo "<p align=\"right\">";
    echo '<button type="submit" name="Validate">' . _T('button_validate') . "</button>";
    echo "</p>";
    echo "</form>\n";
    $_SESSION['form_data'] = array();
    $_SESSION['errors'] = array();
}
use_language_of_site();
use_language_of_visitor();
$open_subscription = read_meta("site_open_subscription");
if (_request('p')) {
    reset_pass(_request('p'), _request('password'));
} else {
    if (_request('user_email')) {
        send_cookie_by_email(_request('user_email'));
    } else {
        if ($reg = _request('register')) {
            if ($open_subscription == 'yes' || $open_subscription == 'moderated') {
                if ($reg == 'data') {
                    send_registration_by_email();
                } else {
                    print_registration_form();
                }
            } else {
                install_html_start(_T('pass_title_register'), 'login');
                // FIXME ? show error ?
            }
Example #2
0
     break;
 case "register":
     //Code Here
     $showregisterform = true;
     break;
 case "lostpass":
     //Code Here
     $showlostpassform = true;
     break;
 case "processlostpassemail":
     //Code Here
     if (email_exists($_POST['email'], true)) {
         // email found reset
         $uid = get_userid_by_email($_POST['email']);
         $profile = get_user_profile($uid);
         $newpass = reset_pass($_POST['email'], $user);
         if ($newpass != false) {
             // send email
             $subject = "Going Dutch password reset";
             $link = '<a href="' . LOGIN_URL . '">login</a>';
             $body = "Someone (most likely you) has requested a password reset for the Going Dutch account with this email address. <br />";
             $body .= "Please reset your password on the profile page after logging in. You can now {$link} with this username and password: <br />";
             $body .= "Username: {$profile['username']}<br />";
             $body .= "Password: {$newpass}<br />";
             $from = '*****@*****.**';
             $from_name = 'Going Dutch';
             smtpmailer($_POST['email'], $from, $from_name, $subject, $body, $replyto = '', $sendas = 'to');
             $registercomplete[] = "A new password has been emailed to {$_POST['email']}";
             $registercomplete[] .= "Click <a href=\"http://" . $_SERVER['HTTP_HOST'] . $_SERVER['PHP_SELF'] . "\">here</a> to login";
             $sendpasscomplete = true;
         } else {
Example #3
0
<html lang="en">
	<head><meta charset="utf-8">
		<title>Casa Ghana</title>
		<link href="css/style.css" rel="stylesheet">
		 <link href="css/bootstrap.min.css" rel="stylesheet">
		 <!-- including font awesome into the project -->
		 <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.4.0/css/font-awesome.min.css">
		<link rel="stylesheet" href="css/font-awesome.min.css">
	</head>
<body id="wrapper">
	<?php 
include 'dbconnect.php';
include 'functions.php';
include 'session.php';
include 'session-expire.php';
reset_pass();
?>
	<div class="container">
		<div class="login-form property-single col-sm-12 col-md-4 col-md-offset-4">
<div class="action-icon"><i class="fa fa-sign-in fa-lg"></i></div>
<div class="">
	<h3 class="text-center">Let's help you recover your account</h3>
</div>
			<form class="" role="form" action="<?php 
$_SERVER['PHP_SELF'];
?>
" method="post">
				
					<div class="form-group">
			     	<input type="password" class="form-control" autofocus name="password" placeholder="New Password" required>
					</div>
Example #4
0
File: reset.php Project: ItsJimi/42
<?php

require_once "include.php";
if (!is_connected()) {
    $request = reset_pass($_POST, $connect);
} else {
    $request = 0;
}
echo $request;