D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
home
/
grandhou
/
public_html
/
album
/
Filename :
index.php
back
Copy
<?php session_start(); error_reporting(0); include("include/configpage.php"); $userId=$_GET['userid']; $permalink=$_GET['permalink']; $sql = "select * from user where id='".$userId."' and permalink='".$permalink."'"; $result = mysqli_query($dbhandle,$sql); while($row = mysqli_fetch_array($result)) { $name=$row['name']; $userEmail=$row['emailid']; $userId=$row['id']; $image=$row['bookimage']; } if(isset($_POST['submit'])) { $emailid=$_POST['emailid']; if($userEmail==$emailid) { $extra="albums.php?userid=".$userId."&permalink=".$permalink;// $_SESSION['alogin']=$emailid; $_SESSION['id']=$userId; $host=$_SERVER['HTTP_HOST']; $uri=rtrim(dirname($_SERVER['PHP_SELF']),'/\\'); header("location:http://$host$uri/$extra"); exit(); } else { $_SESSION['errmsg']="Invalid username or password"; $extra="index.php?userid=".$userId."&permalink=".$permalink; $host = $_SERVER['HTTP_HOST']; $uri = rtrim(dirname($_SERVER['PHP_SELF']),'/\\'); header("location:http://$host$uri/$extra"); exit(); } } ?> <!doctype html> <html> <head> <meta charset="utf-8"> <title><?php echo $permalink;?></title> <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" > <link rel="shortcut icon" href="favicon.ico"> <link href="album-css/album.css" rel="stylesheet" type="text/css"> <link rel="preconnect" href="https://fonts.gstatic.com"> <link href="https://fonts.googleapis.com/css2?family=Raleway:wght@400;700&display=swap" rel="stylesheet"> </head> <body> <div class="coverwrap" style="background-image: url(../album/album-admin/upload/<?php echo $image;?>);"> <div class="cover-text"><h2><?php echo $name;?></h2><br> <span style="color:red;" ><?php echo htmlentities($_SESSION['errmsg']); ?><?php echo htmlentities($_SESSION['errmsg']="");?></span> <form method="post" action=""> <input type="email" name="emailid" class="input" value="Enter Email ID" onclick="this.value=''"> <button type="submit" class="b" name="submit">VIEW GALLERY</button> </form> </div> </div> </body> </html>