This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- | |
-- Database: `image` | |
-- | |
CREATE TABLE `photo` ( | |
`photo_id` int(11) NOT NULL, | |
`photo_name` varchar(100) NOT NULL | |
) ENGINE=InnoDB DEFAULT CHARSET=latin1; | |
-- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$conn = new mysqli('localhost', 'root', '', 'image'); | |
if(ISSET($_POST['save'])){ | |
if($_FILES['image']['name'] == ""){ | |
echo '<script>alert("Veuillez selectionner une image")</script>'; | |
echo '<script>window.location = "index.php"</script>'; | |
}else{ | |
$image = addslashes(file_get_contents($_FILES['image']['tmp_name'])); | |
$image_name = addslashes($_FILES['image']['name']); | |
$image_size = getimagesize($_FILES['image']['tmp_name']); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang = "en"> | |
<head> | |
<link rel = "stylesheet" type = "text/css" href = "css/bootstrap.css"/> | |
<link rel = "stylesheet" type = "text/css" href = "css/style.css"/> | |
<meta charset = "UTF-8" name= "viewport" content = "width=device-width, initial-scale=1" /> | |
</head> | |
<body> | |
<nav class = "navbar navbar-default"> | |
<div class = "container-fluid"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang = "en"> | |
<head> | |
<link rel = "stylesheet" type = "text/css" href = "css/bootstrap.css"/> | |
<link rel = "stylesheet" type = "text/css" href = "css/style.css"/> | |
<meta charset = "UTF-8" name= "viewport" content = "width=device-width, initial-scale=1" /> | |
</head> | |
<body> | |
<nav class = "navbar navbar-default" style="background-color: #337ab7;"> | |
<div class = "container-fluid"> |
NewerOlder