mirror of https://github.com/ColorlibHQ/gentelella
push
parent
cf867cbafc
commit
0c745891d7
|
@ -1,8 +1,8 @@
|
|||
<?php
|
||||
session_start();
|
||||
include('C:\xampp\htdocs\developgetpet\includes\config.php');
|
||||
$ID=$_SESSION['ID'];
|
||||
$sql = "SELECT * from pet_adopter where ID=:ID";
|
||||
$ID=$_SESSION['adopterID'];
|
||||
$sql = "SELECT * from petadopter where adopterID=:ID";
|
||||
$query=$dbh->prepare($sql);
|
||||
$query->bindParam(':ID',$ID,PDO::PARAM_STR);
|
||||
$query->execute();
|
||||
|
@ -82,7 +82,7 @@ $query3->execute();
|
|||
{
|
||||
echo '<script>alert("Your Account Updated Successfully!")</script>';
|
||||
$ID=$_SESSION['ID'];
|
||||
$sql = "SELECT * from pet_adopter where ID=:ID";
|
||||
$sql = "SELECT * from petadopter where adopterID=:ID";
|
||||
$query=$dbh->prepare($sql);
|
||||
$query->bindParam(':ID',$ID,PDO::PARAM_STR);
|
||||
$query->execute();
|
||||
|
@ -110,7 +110,7 @@ if($query->rowCount()>0)
|
|||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
|
||||
<title>GetPet</title>
|
||||
<title>GETPET</title>
|
||||
|
||||
<!-- Bootstrap -->
|
||||
<link href="../vendors/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet">
|
||||
|
@ -129,7 +129,7 @@ if($query->rowCount()>0)
|
|||
<div class="col-md-3 left_col">
|
||||
<div class="left_col scroll-view">
|
||||
<div class="navbar nav_title" style="border: 0;">
|
||||
<a href="index.html" class="site_title"><i class="fa fa-paw"></i> <span>      GetPet!</span></a>
|
||||
<a href="index.html" class="site_title"><i class="fa fa-paw"></i> <span>      GETPET</span></a>
|
||||
</div>
|
||||
|
||||
<div class="clearfix"></div>
|
||||
|
@ -141,7 +141,7 @@ if($query->rowCount()>0)
|
|||
</div>
|
||||
<div class="profile_info">
|
||||
<span>Welcome,</span>
|
||||
<h2><?php echo ($result->Firstname);?> <?php echo ($result->Lastname);?></h2>
|
||||
<h2><?php echo ($result->adopterFirstname);?> <?php echo ($result->adopterLastname);?></h2>
|
||||
</div>
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
|
@ -284,7 +284,7 @@ if($query->rowCount()>0)
|
|||
<ul class=" navbar-right">
|
||||
<li class="nav-item dropdown open" style="padding-left: 15px;">
|
||||
<a href="javascript:;" class="user-profile dropdown-toggle" aria-haspopup="true" id="navbarDropdown" data-toggle="dropdown" aria-expanded="false">
|
||||
<img src="images/img.jpg" alt=""><?php echo ($result->Firstname);?> <?php echo ($result->Lastname);?>
|
||||
<img src="images/img.jpg" alt=""><?php echo ($result->adopterFirstname);?> <?php echo ($result->adopterLastname);?>
|
||||
</a>
|
||||
<div class="dropdown-menu dropdown-usermenu pull-right" aria-labelledby="navbarDropdown">
|
||||
<a class="dropdown-item" href="javascript:;" onclick="document.getElementById('id01').style.display='block'" class="w3-button w3-black"> Profile</a>
|
||||
|
|
|
@ -20,13 +20,13 @@ if(isset($_POST['login']))
|
|||
session_regenerate_id();
|
||||
$_SESSION['adID'] = $results['adID'];
|
||||
|
||||
echo '<script>alert("Login Successfully!")</script>';
|
||||
echo '<script>alert("Login Successfully!!!")</script>';
|
||||
echo "<script type ='text/javascript'> document.location='http://localhost/developgetpet/web/AdminDashboard.php'</script>";
|
||||
|
||||
|
||||
}
|
||||
|
||||
$sql1 = "SELECT * FROM petowner WHERE Username = :Username AND Password =:Password";
|
||||
$sql1 = "SELECT * FROM petowner WHERE ownerUsername = :Username AND ownerPassword =:Password";
|
||||
$query1 = $dbh->prepare($sql1);
|
||||
$query1->bindParam(':Username', $Username,PDO::PARAM_STR);
|
||||
$query1->bindParam(':Password', $Password,PDO::PARAM_STR);
|
||||
|
@ -38,28 +38,28 @@ if(isset($_POST['login']))
|
|||
{
|
||||
|
||||
session_regenerate_id();
|
||||
$_SESSION['ID'] = $results1['ID'];
|
||||
$_SESSION['Firstname'] = $results1['Firstname'];
|
||||
$_SESSION['Lastname'] = $results1['Lastname'];
|
||||
$_SESSION['ownerID'] = $results1['ownerID'];
|
||||
$_SESSION['ownerFirstname'] = $results1['ownerFirstname'];
|
||||
$_SESSION['ownerLastname'] = $results1['ownerLastname'];
|
||||
|
||||
$ID=$_SESSION['ID'];
|
||||
$ID=$_SESSION['ownerID'];
|
||||
|
||||
$Date=($_POST['Date']);
|
||||
|
||||
$sql="update login set Date=:Date where ID=$ID";
|
||||
$sql="update login set loginDate=:Date where userID=$ID";
|
||||
$query=$dbh->prepare($sql);
|
||||
$query->bindParam(':Date',$Date,PDO::PARAM_STR);
|
||||
$query->execute();
|
||||
|
||||
echo '<script>alert("Login Successfully!")</script>';
|
||||
echo "<script type ='text/javascript'> document.location='http://localhost/GETPET/web/PetOwnerDashboard.php'</script>";
|
||||
echo $_SESSION['ID'];
|
||||
echo $_SESSION['Firstname'];
|
||||
echo $_SESSION['Lastname'];
|
||||
echo '<script>alert("Login Successfully!!!")</script>';
|
||||
echo "<script type ='text/javascript'> document.location='http://localhost/developgetpet/dashboard/PetOwnerDashboard.php'</script>";
|
||||
echo $_SESSION['ownerID'];
|
||||
echo $_SESSION['ownerFirstname'];
|
||||
echo $_SESSION['ownerLastname'];
|
||||
|
||||
}
|
||||
|
||||
$sql2 = "SELECT * FROM pet_adopter WHERE Username = :Username AND Password =:Password";
|
||||
$sql2 = "SELECT * FROM petadopter WHERE adopterUsername = :Username AND adopterPassword =:Password";
|
||||
$query2 = $dbh->prepare($sql2);
|
||||
$query2->bindParam(':Username', $Username,PDO::PARAM_STR);
|
||||
$query2->bindParam(':Password', $Password,PDO::PARAM_STR);
|
||||
|
@ -71,28 +71,28 @@ if(isset($_POST['login']))
|
|||
{
|
||||
|
||||
session_regenerate_id();
|
||||
$_SESSION['ID'] = $results2['ID'];
|
||||
$_SESSION['Firstname'] = $results2['Firstname'];
|
||||
$_SESSION['Lastname'] = $results2['Lastname'];
|
||||
$_SESSION['adopterID'] = $results2['adopterID'];
|
||||
$_SESSION['adopterFirstname'] = $results2['adopterFirstname'];
|
||||
$_SESSION['adopterLastname'] = $results2['adopterLastname'];
|
||||
|
||||
$ID=$_SESSION['ID'];
|
||||
$ID=$_SESSION['adopterID'];
|
||||
|
||||
$Date=($_POST['Date']);
|
||||
|
||||
$sql="update login set Date=:Date where ID=$ID";
|
||||
$sql="update login set loginDate=:Date where userID=$ID";
|
||||
$query=$dbh->prepare($sql);
|
||||
$query->bindParam(':Date',$Date,PDO::PARAM_STR);
|
||||
$query->execute();
|
||||
|
||||
echo '<script>alert("Login Successfully!")</script>';
|
||||
echo '<script>alert("Login Successfully!!!")</script>';
|
||||
echo "<script type ='text/javascript'> document.location='http://localhost/developgetpet/dashboard/PetAdopterDashboard.php'</script>";
|
||||
echo $_SESSION['ID'];
|
||||
echo $_SESSION['Firstname'];
|
||||
echo $_SESSION['Lastname'];
|
||||
echo $_SESSION['adopterID'];
|
||||
echo $_SESSION['adopterFirstname'];
|
||||
echo $_SESSION['adopterLastname'];
|
||||
|
||||
}
|
||||
|
||||
$sql3 = "SELECT * FROM animal_welfare_agency WHERE Username = :Username AND Password =:Password";
|
||||
$sql3 = "SELECT * FROM animalwelfareorganization WHERE orgUsername = :Username AND orgPassword =:Password";
|
||||
$query3 = $dbh->prepare($sql3);
|
||||
$query3->bindParam(':Username', $Username,PDO::PARAM_STR);
|
||||
$query3->bindParam(':Password', $Password,PDO::PARAM_STR);
|
||||
|
@ -104,21 +104,21 @@ if(isset($_POST['login']))
|
|||
{
|
||||
|
||||
session_regenerate_id();
|
||||
$_SESSION['ID'] = $results3['ID'];
|
||||
$_SESSION['OrganizationName'] = $results3['OrganizationName'];
|
||||
$_SESSION['OrganizationManager'] = $results3['OrganizationManager'];
|
||||
$_SESSION['orgID'] = $results3['orgID'];
|
||||
$_SESSION['orgName'] = $results3['orgName'];
|
||||
$_SESSION['orgManager'] = $results3['orgManager'];
|
||||
|
||||
$ID=$_SESSION['ID'];
|
||||
$ID=$_SESSION['orgID'];
|
||||
|
||||
$Date=($_POST['Date']);
|
||||
|
||||
$sql="update login set Date=:Date where ID=$ID";
|
||||
$sql="update login set loginDate=:Date where userID=$ID";
|
||||
$query=$dbh->prepare($sql);
|
||||
$query->bindParam(':Date',$Date,PDO::PARAM_STR);
|
||||
$query->execute();
|
||||
|
||||
echo '<script>alert("Login Successfully!")</script>';
|
||||
echo "<script type ='text/javascript'> document.location='http://localhost/GETPET/web/AnimalWelfareAgencyDashboard.php'</script>";
|
||||
echo '<script>alert("Login Successfully!!!")</script>';
|
||||
echo "<script type ='text/javascript'> document.location='http://localhost/developgetpet/dashboard/AnimalWelfareOrganizationDashboard.php'</script>";
|
||||
echo $_SESSION['ID'];
|
||||
echo $_SESSION['OrganizationName'];
|
||||
echo $_SESSION['OrganizationManager'];
|
||||
|
@ -126,7 +126,7 @@ if(isset($_POST['login']))
|
|||
}
|
||||
|
||||
else
|
||||
echo '<script>alert("Invalid Account!")</script>';
|
||||
echo '<script>alert("Invalid Account!!!")</script>';
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -99,7 +99,7 @@ $Date=$query->fetchColumn();
|
|||
<div class='collapse navbar-collapse'>
|
||||
<ul>
|
||||
<li>
|
||||
<a href="http://localhost/GETPET/web/AdminDashboard.php">Home</a>
|
||||
<a href="http://localhost/developgetpet/web/AdminDashboard.php">Home</a>
|
||||
</li>
|
||||
<!--<li style = "width:160px;">
|
||||
<a href="#activity" class="scroll">Activity Log</a>
|
||||
|
@ -150,7 +150,7 @@ $Date=$query->fetchColumn();
|
|||
<legend style="font-size: 20px">Total Pet Owner</legend>
|
||||
<fieldset>
|
||||
<legend><?php echo $pet_owner; ?></legend>
|
||||
<button type="button" name="PetOwner" style="background-color:#00cdc1;border-radius:2px;color:white;width:100px;height:35px;border:none;"><a href="http://localhost/GETPET/web/PetOwner.php" style="color:white;">View</a></button>
|
||||
<button type="button" name="PetOwner" style="background-color:#00cdc1;border-radius:2px;color:white;width:100px;height:35px;border:none;"><a href="http://localhost/developgetpet/web/PetOwner.php" style="color:white;">View</a></button>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="col-md-4 col-sm-4 col-xs-4 w3_agile_services_grid " data-aos="zoom-in">
|
||||
|
@ -164,7 +164,7 @@ $Date=$query->fetchColumn();
|
|||
<legend style="font-size: 20px">Total Pet Adopter</legend>
|
||||
<fieldset>
|
||||
<legend><?php echo $pet_adopter; ?></legend>
|
||||
<button type="button" style="background-color:#00cdc1;border-radius:2px;color:white;width:100px;height:35px;border:none;"><a href="http://localhost/GETPET/web/PetAdopter.php" style="color:white;">View</a></button>
|
||||
<button type="button" style="background-color:#00cdc1;border-radius:2px;color:white;width:100px;height:35px;border:none;"><a href="http://localhost/developgetpet/web/PetAdopter.php" style="color:white;">View</a></button>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="col-md-4 col-sm-4 col-xs-4 w3_agile_services_grid" data-aos="zoom-in">
|
||||
|
@ -178,7 +178,7 @@ $Date=$query->fetchColumn();
|
|||
<legend style="font-size: 20px">Total Animal Welfare Organization</legend>
|
||||
<fieldset>
|
||||
<legend><?php echo $animal_welfare_organization;?></legend>
|
||||
<button type="button" style="background-color:#00cdc1;border-radius:2px;color:white;width:100px;height:35px;border:none;"><a href="http://localhost/GETPET/web/AnimalWelfareOrganization.php" style="color:white;">View</a></button>
|
||||
<button type="button" style="background-color:#00cdc1;border-radius:2px;color:white;width:100px;height:35px;border:none;"><a href="http://localhost/developgetpet/web/AnimalWelfareOrganization.php" style="color:white;">View</a></button>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="col-md-4 col-sm-4 col-xs-4 w3_agile_services_grid" data-aos="zoom-in">
|
||||
|
@ -193,7 +193,7 @@ $Date=$query->fetchColumn();
|
|||
<legend style="font-size: 20px">Total Registered</legend>
|
||||
<fieldset>
|
||||
<legend><legend><?php echo $Registered;?></legend></legend>
|
||||
<button type="button" style="background-color:#00cdc1;border-radius:2px;color:white;width:100px;height:35px;border:none;"><a href="http://localhost/GETPET/web/TotalRegistered.php" style="color:white;">View</a></button>
|
||||
<button type="button" style="background-color:#00cdc1;border-radius:2px;color:white;width:100px;height:35px;border:none;"><a href="http://localhost/developgetpet/web/TotalRegistered.php" style="color:white;">View</a></button>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="col-md-4 col-sm-4 col-xs-4 w3_agile_services_grid" data-aos="zoom-in">
|
||||
|
@ -208,7 +208,7 @@ $Date=$query->fetchColumn();
|
|||
<legend style="font-size: 20px">Total User Log Today</legend>
|
||||
<fieldset>
|
||||
<legend><legend><?php echo $Date;?></legend></legend>
|
||||
<button type="button" style="background-color:#00cdc1;border-radius:2px;color:white;width:100px;height:35px;border:none;"><a href="http://localhost/GETPET/web/UserLogToday.php" style="color:white;">View</a></button>
|
||||
<button type="button" style="background-color:#00cdc1;border-radius:2px;color:white;width:100px;height:35px;border:none;"><a href="http://localhost/developgetpet/web/UserLogToday.php" style="color:white;">View</a></button>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="clearfix"> </div>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<?php
|
||||
session_start();
|
||||
include('C:\xampp\htdocs\GETPET\includes\config.php');
|
||||
$query=$dbh->prepare("SELECT COUNT(ID) FROM pet_owner");
|
||||
include('C:\xampp\htdocs\developgetpet\includes\config.php');
|
||||
$query=$dbh->prepare("SELECT COUNT(ownerID) FROM petowner");
|
||||
$query->execute();
|
||||
|
||||
$pet_owner=$query->fetchColumn();
|
||||
|
@ -9,7 +9,7 @@ $pet_owner=$query->fetchColumn();
|
|||
?>
|
||||
|
||||
<?php
|
||||
$query=$dbh->prepare("SELECT COUNT(ID) FROM pet_adopter");
|
||||
$query=$dbh->prepare("SELECT COUNT(adopterID) FROM petadopter");
|
||||
$query->execute();
|
||||
|
||||
$pet_adopter=$query->fetchColumn();
|
||||
|
@ -17,7 +17,7 @@ $pet_adopter=$query->fetchColumn();
|
|||
?>
|
||||
|
||||
<?php
|
||||
$query=$dbh->prepare("SELECT COUNT(ID) FROM animal_welfare_agency");
|
||||
$query=$dbh->prepare("SELECT COUNT(orgID) FROM animalwelfareorganization");
|
||||
$query->execute();
|
||||
|
||||
$animal_welfare_agency=$query->fetchColumn();
|
||||
|
@ -25,7 +25,7 @@ $animal_welfare_agency=$query->fetchColumn();
|
|||
?>
|
||||
|
||||
<?php
|
||||
$query=$dbh->prepare("SELECT COUNT(*) FROM registered ");
|
||||
$query=$dbh->prepare("SELECT COUNT(*) FROM register ");
|
||||
$query->execute();
|
||||
|
||||
$Registered=$query->fetchColumn();
|
||||
|
@ -33,7 +33,7 @@ $Registered=$query->fetchColumn();
|
|||
?>
|
||||
|
||||
<?php
|
||||
$query=$dbh->prepare("SELECT COUNT(*) FROM login WHERE (Date) = (CURDATE())");
|
||||
$query=$dbh->prepare("SELECT COUNT(*) FROM login WHERE (loginDate) = (CURDATE())");
|
||||
$query->execute();
|
||||
|
||||
$Date=$query->fetchColumn();
|
||||
|
@ -100,7 +100,7 @@ $Date=$query->fetchColumn();
|
|||
<ul>
|
||||
|
||||
<li>
|
||||
<a href="http://localhost/GETPET/web/AdminDashboard.php">Home</a>
|
||||
<a href="http://localhost/developgetpet/web/AdminDashboard.php">Home</a>
|
||||
</li>
|
||||
<!--<li style = "width:160px;">
|
||||
<a href="#activity" class="scroll">Activity Log</a>
|
||||
|
@ -124,7 +124,7 @@ $Date=$query->fetchColumn();
|
|||
<div class="dropdown-divider"></div>
|
||||
<a class="dropdown-item" href="#"style="color:black;"><t style="margin-left: 10px;">Settings</t></a>
|
||||
<div class="dropdown-divider"></div>
|
||||
<a class="dropdown-item" href="http://localhost/GETPET/web/Dashboard.php" style="color:black;"><t style="margin-left: 10px;">Log out</t></a>
|
||||
<a class="dropdown-item" href="http://localhost/developgetpet/login-page/login.php" style="color:black;"><t style="margin-left: 10px;">Log out</t></a>
|
||||
</div></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
@ -160,7 +160,7 @@ $Date=$query->fetchColumn();
|
|||
|
||||
<tbody>
|
||||
<?php
|
||||
$sql="SELECT * from pet_adopter";
|
||||
$sql="SELECT * from petadopter";
|
||||
$query=$dbh->prepare($sql);
|
||||
$query->execute();
|
||||
$results=$query->fetchALL(PDO::FETCH_OBJ);
|
||||
|
@ -172,13 +172,13 @@ if($query->rowCount()>0)
|
|||
?>
|
||||
<tr>
|
||||
<td style="text-align:center;"><input type="checkbox" class="checkItem" value="<?php echo htmlentities($result->ID)?>" name="ID[]"></td>
|
||||
<td><?php echo htmlentities($result->ID);?></td>
|
||||
<td><?php echo htmlentities($result->Firstname);?></td>
|
||||
<td><?php echo htmlentities($result->Lastname);?></td>
|
||||
<td><?php echo htmlentities($result->ContactNo);?></td>
|
||||
<td><?php echo htmlentities($result->Address);?></td>
|
||||
<td><?php echo '<img src="data:image/jpeg;base64,'.base64_encode($result->Picture).'" width="75"; height="80">';?></td>
|
||||
<td><?php echo htmlentities($result->Email);?></td>
|
||||
<td><?php echo htmlentities($result->adopterID);?></td>
|
||||
<td><?php echo htmlentities($result->adopterFirstname);?></td>
|
||||
<td><?php echo htmlentities($result->adopterLastname);?></td>
|
||||
<td><?php echo htmlentities($result->adopterContactNo);?></td>
|
||||
<td><?php echo htmlentities($result->adopterAddress);?></td>
|
||||
<td><?php echo"<img src = '/GETPET/web/images/$result->adopterPicture' style = height:80px; width:80px;/>";?></td>
|
||||
<td><?php echo htmlentities($result->adopterEmail);?></td>
|
||||
<td><?php echo htmlentities($result->Role);?></td>
|
||||
<td><input type="submit" name="delete" value="Delete" name="ID[]" onclick="return confirm('Are you sure you want to delete this data?')" class="btn btn-danger"></td>
|
||||
</tr>
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
<?php
|
||||
session_start();
|
||||
include('C:\xampp\htdocs\GETPET\includes\config.php');
|
||||
include('C:\xampp\htdocs\developgetpet\includes\config.php');
|
||||
$ID=$_SESSION['ID'];
|
||||
$sql = "SELECT * from pet_adopter where ID=:ID";
|
||||
$sql = "SELECT * from petadopter where adopterID=:ID";
|
||||
$query=$dbh->prepare($sql);
|
||||
$query->bindParam(':ID',$ID,PDO::PARAM_STR);
|
||||
$query->execute();
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<?php
|
||||
session_start();
|
||||
include('C:\xampp\htdocs\GETPET\includes\config.php');
|
||||
$query=$dbh->prepare("SELECT COUNT(ID) FROM pet_owner");
|
||||
include('C:\xampp\htdocs\developgetpet\includes\config.php');
|
||||
$query=$dbh->prepare("SELECT COUNT(ownerID) FROM petowner");
|
||||
$query->execute();
|
||||
|
||||
$pet_owner=$query->fetchColumn();
|
||||
|
@ -9,7 +9,7 @@ $pet_owner=$query->fetchColumn();
|
|||
?>
|
||||
|
||||
<?php
|
||||
$query=$dbh->prepare("SELECT COUNT(ID) FROM pet_adopter");
|
||||
$query=$dbh->prepare("SELECT COUNT(adopterID) FROM petadopter");
|
||||
$query->execute();
|
||||
|
||||
$pet_adopter=$query->fetchColumn();
|
||||
|
@ -17,7 +17,7 @@ $pet_adopter=$query->fetchColumn();
|
|||
?>
|
||||
|
||||
<?php
|
||||
$query=$dbh->prepare("SELECT COUNT(ID) FROM animal_welfare_agency");
|
||||
$query=$dbh->prepare("SELECT COUNT(orgID) FROM animalwelfareorganization");
|
||||
$query->execute();
|
||||
|
||||
$animal_welfare_agency=$query->fetchColumn();
|
||||
|
@ -25,7 +25,7 @@ $animal_welfare_agency=$query->fetchColumn();
|
|||
?>
|
||||
|
||||
<?php
|
||||
$query=$dbh->prepare("SELECT COUNT(*) FROM registered ");
|
||||
$query=$dbh->prepare("SELECT COUNT(*) FROM register");
|
||||
$query->execute();
|
||||
|
||||
$Registered=$query->fetchColumn();
|
||||
|
@ -33,7 +33,7 @@ $Registered=$query->fetchColumn();
|
|||
?>
|
||||
|
||||
<?php
|
||||
$query=$dbh->prepare("SELECT COUNT(*) FROM login WHERE (Date) = (CURDATE())");
|
||||
$query=$dbh->prepare("SELECT COUNT(*) FROM login WHERE (loginDate) = (CURDATE())");
|
||||
$query->execute();
|
||||
|
||||
$Date=$query->fetchColumn();
|
||||
|
@ -100,7 +100,7 @@ $Date=$query->fetchColumn();
|
|||
<ul>
|
||||
|
||||
<li>
|
||||
<a href="http://localhost/GETPET/web/AdminDashboard.php">Home</a>
|
||||
<a href="http://localhost/developgetpet/web/AdminDashboard.php">Home</a>
|
||||
</li>
|
||||
<!--<li style = "width:160px;">
|
||||
<a href="#activity" class="scroll">Activity Log</a>
|
||||
|
@ -124,7 +124,7 @@ $Date=$query->fetchColumn();
|
|||
<div class="dropdown-divider"></div>
|
||||
<a class="dropdown-item" href="#"style="color:black;"><t style="margin-left: 10px;">Settings</t></a>
|
||||
<div class="dropdown-divider"></div>
|
||||
<a class="dropdown-item" href="http://localhost/GETPET/web/Dashboard.php" style="color:black;"><t style="margin-left: 10px;">Log out</t></a>
|
||||
<a class="dropdown-item" href="http://localhost/developgetpet/login-page/login.php" style="color:black;"><t style="margin-left: 10px;">Log out</t></a>
|
||||
</div></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
@ -160,7 +160,7 @@ $Date=$query->fetchColumn();
|
|||
|
||||
<tbody>
|
||||
<?php
|
||||
$sql="SELECT * from pet_owner";
|
||||
$sql="SELECT * from petowner";
|
||||
$query=$dbh->prepare($sql);
|
||||
$query->execute();
|
||||
$results=$query->fetchALL(PDO::FETCH_OBJ);
|
||||
|
@ -172,13 +172,13 @@ if($query->rowCount()>0)
|
|||
?>
|
||||
<tr>
|
||||
<td style="text-align:center;"><input type="checkbox" class="checkItem" value="<?php echo htmlentities($result->ID)?>" name="ID[]"></td>
|
||||
<td><?php echo htmlentities($result->ID);?></td>
|
||||
<td><?php echo htmlentities($result->Firstname);?></td>
|
||||
<td><?php echo htmlentities($result->Lastname);?></td>
|
||||
<td><?php echo htmlentities($result->ContactNo);?></td>
|
||||
<td><?php echo htmlentities($result->Address);?></td>
|
||||
<td><?php echo '<img src="data:image/jpeg;base64,'.base64_encode($result->Picture).'" width="75"; height="80">';?></td>
|
||||
<td><?php echo htmlentities($result->Email);?></td>
|
||||
<td><?php echo htmlentities($result->ownerID);?></td>
|
||||
<td><?php echo htmlentities($result->ownerFirstname);?></td>
|
||||
<td><?php echo htmlentities($result->ownerLastname);?></td>
|
||||
<td><?php echo htmlentities($result->ownerContactNo);?></td>
|
||||
<td><?php echo htmlentities($result->ownerAddress);?></td>
|
||||
<td><?php echo"<img src = '/GETPET/web/images/$result->ownerPicture' style = height:80px; width:80px;/>";?></td>
|
||||
<td><?php echo htmlentities($result->ownerEmail);?></td>
|
||||
<td><?php echo htmlentities($result->Role);?></td>
|
||||
<td><input type="submit" name="delete" value="Delete" name="ID[]" onclick="return confirm('Are you sure you want to delete this data?')" class="btn btn-danger"></td>
|
||||
<?php $cnt=$cnt+1;}} ?>
|
||||
|
@ -189,7 +189,7 @@ if($query->rowCount()>0)
|
|||
if(isset($_POST['delete']))
|
||||
{
|
||||
foreach ($_POST['ID'] as $ID){
|
||||
$query="Delete from pet_owner where ID=:ID";
|
||||
$query="Delete from petowner where ID=:ID";
|
||||
$query1 = $dbh->prepare($query);
|
||||
$query1->bindValue('ID',$ID);
|
||||
$query1->execute();
|
||||
|
|
Loading…
Reference in New Issue