Skip to document

Admin Master Authentication

mini project admin side
Course

Bachelor of Computer Applications (BCA2020)

999+ Documents
Students shared 2571 documents in this course
Academic year: 2023/2024
Uploaded by:
Anonymous Student
This document has been uploaded by a student, just like you, who decided to remain anonymous.
Mahatma Gandhi University

Comments

Please sign in or register to post comments.

Preview text

We can start our project with the following steps.

  1. Create a new project folder in to the directory Folder name as your own project title. Eg: Puddle net , gift cart etc....

For wamp users

For xamp users

  1. Create two folders inside the project folder.

  2. Then open Visual studio code and click

Open project folder to vs code.

  1. Then our project will open to vs code. After maximise Guest folder and create a new file as

Note : The rouded option can use to create a new file in to Guest folder

  1. After we can include our external files and to the page login for our login page css and javascript proper working.

  2. Then start wamp server or xamp server and open chrome or any other browser.

  3. In chrome , type for run our project

  4. So we can see our project folder , and we created project subfolders. Then click - can see our output.

Our Output of login page

  1. Then include to login code.

Then Create a new file in the project folder not in the Guest folder and named as

Note : The file will create outside the folders admin and Guest

Then given code to the dboperation for connect database to our project.

Note : You can give your database name placed to the field of mentioned databasename.

<?php class dboperation { public $con,$res;

function __construct() { $this->con=mysqli_connect("localhost","root","","databasename"); // Check connection if (!$this->con) { die("Connection failed: ". mysqli_connect_error()); }

} public function query($sql) { //$this->connect(); $this->res=mysqli_query($this->con,$sql); return $this->res; }

}

?>

Then open your project created database and open

  1. After open click insert tab to insert values to database.

  2. Then open loginaction and declare two variables for store input values from we given for login to the login action.

  3. Then create include our file page to our page for checking databse connectivity and create an for dboperation.

Then write the queries for checking the login activity of is valid or invalid.

$sql="select * from tbllogin where username='$username' and password='$password'"; $res=$obj->query($sql);

if(mysqli_num_rows($res)== 1 ) { $row=mysqli_fetch_array($res); if($row["role"]=="Admin" && $row["role"]=="Confirm" ) { header("location:..\Admin\index"); } else {

echo "<script>alert('Invalid Username/Password!!'); window='login'</script>";; } }

Full code of page.

  1. Open maximize admin folder and create a new file named as and give an tag and a title
Was this document helpful?

Admin Master Authentication

Course: Bachelor of Computer Applications (BCA2020)

999+ Documents
Students shared 2571 documents in this course
Was this document helpful?
Santhisoft Technologies, R&D wing of Santhigiri College, Vazhithala, www.santhisoft.com
We can start our project with the following steps.
1. Create a new project folder in to the directory
Folder name as your own project title. Eg: Puddle net , gift cart
etc….
For wamp users
For xamp users
2. Create two folders inside the project folder.
3. Then open Visual studio code and click