Create Dynamic Image Fancybox Gallery with jQuery, PHP & MySQL
In this Post We Will Explain About is Create Dynamic Image Fancybox Gallery with jQuery, PHP & MySQL With Example and Demo.Welcome on Pakainfo.com – Examples, The best For Learn web development Tutorials,Demo with Example! Hi Dear Friends here u can know to Responsive Photo Gallery with jQuery Example
In this post we will show you Best way to implement Creating dynamic Photo Gallery with jQuery, PHP & MySQL, hear for How to Create Dynamic Image Gallery with jQuery, PHP & MySQL with Download .we will give you demo,Source Code and examples for implement Step By Step Good Luck!.
Creating simple Database
CREATE TABLE `Gallery_photo` ( `liveImgId` INT(11) NOT NULL AUTO_INCREMENT, `information` text NOT NULL, `img_location` VARCHAR(150) NOT NULL, PRIMARY KEY(`liveImgId`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
Include External Libs
index.php
jquery PHP Gallery using Fancybox Example Fancybox - Fancy jQuery lightbox alternative
Photo List Photo
Information Gallery Location Gallery connect_error) { die("Connection failed: " . $db_con->connect_error); } $sql="select * from Gallery_photo"; $query=$db_con->query($sql); while($datarow=$query->fetch_array()){ ?>">
do_upload.php
connect_error) { die("Connection failed: " . $db_con->connect_error); } $information=$_POST['information']; $getDataInfo = PATHINFO($_FILES["image"]["name"]); if (empty($_FILES["image"]["name"])){ $_SESSION['galleryError']="Upload Failed. Sorry File empty!"; header('img_location:index.php'); } else{ if ($getDataInfo['extension'] == "jpg" OR $getDataInfo['extension'] == "jpeg" OR $getDataInfo['extension'] == "png") { $newdataFile = $getDataInfo['filename'] . "_" . time() . "." . $getDataInfo['extension']; move_uploaded_file($_FILES["image"]["tmp_name"], "upload/" . $newdataFile); $img_location = "upload/" . $newdataFile; $sql="insert into Gallery_photo (information, img_location) values ('$information', '$img_location')"; $query=$db_con->query($sql); if($query){ $_SESSION['success']="Gallery Photo uploaded Successfully Good Lick!"; } else{ $_SESSION['galleryError']="Something went wrong. Please check to Can't upload Photo!"; } header('img_location:index.php'); } else{ $_SESSION['galleryError']="Upload Failed. Sorry Please check upload any format JPG or PNG Gallery_photo only!"; header('img_location:index.php'); } } ?>
You are Most welcome in my youtube Channel Please subscribe my channel. and give me FeedBack.
More Details……
Angularjs Example
I hope you have Got What is Fancybox – Fancy jQuery lightbox alternative And how it works.I would Like to have FeedBack From My Blog(Pakainfo.com) readers.Your Valuable FeedBack,Any Question,or any Comments about This Article(Pakainfo.com) Are Most Always Welcome.