PHP MySQL Image Gallery. The admin section contain the following : Add New Album Album List Edit & Delete Album Add Image Image List Edit & Delete Image.

Slides:



Advertisements
Similar presentations
JQuery MessageBoard. Lets use jQuery and AJAX in combination with a database to update and retrieve information without refreshing the page. Here we will.
Advertisements

Microsoft TM SharePoint Content Management SystemTutorial By Mazen Abdallah Student Assistant at CNS 2010.
Group X7 – Year 2010/2011 – First Year Team Project.
Access - Project 1 l What Is a Database? –A Collection of Data –Organized in a manner to allow: »Access »Retrieval »Use of That Data.
Guide to Oracle10G1 Introduction To Forms Builder Chapter 5.
A Guide to MySQL 3. 2 Objectives Start MySQL and learn how to use the MySQL Reference Manual Create a database Change (activate) a database Create tables.
Digital Media Webspace Publishing Quick Start. 1. Login to Webspace using your UT-EID and password at:
Microsoft Access 2007 Microsoft Access 2007 Introduction to Database Programs.
Ch 9 Managing Active Directory User Accounts. Objectives Create Organizational Unit Creating User Accounts in Active Directory Disabling, Enabling, and.
8/16/2015alicewebmaster1 Create contents with the new Content Management System (Drupal): Workflow for page editors.
Deployment Management The following screens demonstrate how to: 1. Access and view deployments 2. Create a new local deployment 3. Create and modify a.
Website Tutorial. Administration  Log on by clicking Login on the footer of almost any page  Your Username is.
Lecture 3 – Data Storage with XML+AJAX and MySQL+socket.io
A Guide to SQL, Eighth Edition Chapter Three Creating Tables.
Session 5: Working with MySQL iNET Academy Open Source Web Development.
® IBM Software Group © 2009 IBM Corporation Rational Publishing Engine RQM Multi Level Report Tutorial David Rennie, IBM Rational Services A/NZ
If This Bar Is Light Blue – It Is Info That You Should Read! Helpful Hint There Will Often Be A Colored Title Bar At The Top Of A Slide.
Scoring Program Updates & XML upload to the NSRCA web site July 2013.
Web Based Inventory Site Building Room Asset Number Category Type Description Serial Number Manufacturer Model Vendor Name Acquired Date P O Number Budget.
Chapter 1 Databases and Database Objects: An Introduction
© 2003 By Default! A Free sample background from Slide 1 Week 2  Free PHP Hosting Setup  PHP Backend  Backend Security 
Tutorial 121 Creating a New Web Forms Page You will find that creating Web Forms is similar to creating traditional Windows applications in Visual Basic.
PHP meets MySQL.
1.Getting Started 2.Modifying Design 3.Page 4.News 5.Events 6.Photo Gallery 7.Newsletter Index Training 15 th Mar., 2011.
Alice 2.0 Introductory Concepts and Techniques Project 1 Exploring Alice and Object-Oriented Programming.
Introduction to MySQL Lab no. 10 Advance Database Management System.
Installing and Using MySQL and phpMyAdmin. Last Time... Installing Apache server Installing PHP Running basic PHP scripts on the server Not necessary.
CIS 3051 PHP – Chapter 27 Building A Shopping Cart.
Open Source Server Side Scripting ECA 236 Open Source Server Side Scripting Installation and Testing.
Hello We are looking for a coder to code the following We have a network that has different sites: we need an application that will scan the network and.
CAKEPHP Blog tutorial. what you’ll need examples/blog/blog.html 2  A running web server  A database server.
Looking for simple php script Language: PHP Must be php>>>>> I can not use an other language Budget: $30.0 If more than $30.0 Please do not bid Login page.
0 eCPIC User Training: Dependency Mapper These training materials are owned by the Federal Government. They can be used or modified only by FESCOM member.
With Microsoft Office 2007 Introductory© 2008 Pearson Prentice Hall1 PowerPoint Presentation to Accompany GO! with Microsoft ® Office 2007 Introductory.
Nickelodeon – Blogs User Guide. 1. Introduction The admin tool allows you to create and publish blog posts easily and efficiently along with managing.
14. Uploading Files to MySQL Database. M. Udin Harun Al Rasyid, S.Kom, Ph.D Desain dan.
Website Editing From Gingerweb The Image Gallery.
A Guide to MySQL 3. 2 Introduction  Structured Query Language (SQL): Popular and widely used language for retrieving and manipulating database data Developed.
JDBC Tutorial CSCI 201L Jeffrey Miller, Ph.D. HTTP :// WWW - SCF. USC. EDU /~ CSCI 201 USC CSCI 201L.
Course ILT Forms and queries Unit objectives Create forms by using AutoForm and the Form Wizard, and add or modify form headers and footers Open and enter.
Install Appaserver ©Tim Riley. Apache Group ©Tim Riley Add yourself to the apache group. Both the apache user and group are called “www-data”. This step.
Creating a simple database This shows you how to set up a database using PHPMyAdmin (installed with WAMP)
MS-Access XP Lesson 4. Modifying Queries 1.Select query in queries 2.Click design button or Right click on query and click design view 3.Change query.
Wordpress Website Project Requirement. Home – Slider and News Admin can add news. All the 12 LATEST NEWS TITLE will be listed here. TOP = NEWEST, BOTTOM.
Setting up Dreamweaver to use your local WAMP testing Server
P rinceton I ntralink D ata A ccess Available Through You can now view files in Intralink using FROTOOLS Revision 0 May 16, 2005.
ClubRunner 101 By Pamela Walther
Managing Database With Oracle Replacement for Ch10 COP 4708.
Class 3Intro to Databases Class 4 Simple Example of a Database We’re going to build a simple example of a database, which will allow us to register users.
HTML Help For MGS 351 Final Project Website. Agenda Getting Started – Must-Do’s – Working from an off-campus computer – Other Resources Working with HTML.
PHP Form Processing * referenced from
Web Application Design. Data –What data is available? –How do we store it or how is it stored in the DB? Schema Data types Etc. –Where is the data?
This document has been submitted on a confidential basis and contains proprietary information belonging to BigMachines, Inc. No part of this document may.
Creating Web Pages with Links, Images, and Embedded Style Sheets
Fab25 User Training Cerium Labs LabCollector - LIMS Lynette Ballast.
Lindsey Velez, Director of Instructional Technology Single Sign-On One Click.
QUIZ MODULE. You can Add the quiz title or heading Select the to and form date for the quiz Description of quiz Prize being offered – If you have any.
Joomla Awdhesh Kumar Singsys Pte Ltd. What is Joomla? Joomla is an award-winning content management system (CMS), which enables you to build Web sites.
How to use Drupal Awdhesh Kumar (Team Leader) Presentation Topic.
MicrosoftTM SharePoint Content Management SystemTutorial
3 A Guide to MySQL.
Intro to WordPress (Using XAMPP)
Update your Company Profile on TheYachtMarket
CONTENT MANAGEMENT SYSTEM CSIR-NISCAIR, New Delhi
Storing Images Connect to the server using the correct username and password. $conn = mysql_connect(“yourserver”, “joeuser”, “yourpass”); Create the database.
Database application MySQL Database and PhpMyAdmin
Microsoft Access 2003 Illustrated Complete
Step by step instructions to Add an Admin User in WordPress utilizing FTP Guided By: - WPGLOBALSUPPORTWPGLOBALSUPPORT.
User Guide Portman Concur
Access Lesson 2 Creating a Database
Presentation transcript:

PHP MySQL Image Gallery

The admin section contain the following : Add New Album Album List Edit & Delete Album Add Image Image List Edit & Delete Image

And the visitor page contain these : Display Album List Display Image List Display Image Detail

Now, before we go straight to the codes we need to talk about the database design, directory layout, and configurations.

Database Design CREATE TABLE tbl_album ( al_id INT NOT NULL AUTO_INCREMENT, al_name VARCHAR(64) NOT NULL, al_description TEXT NOT NULL, al_image VARCHAR(64) NOT NULL, al_date DATETIME NOT NULL, PRIMARY KEY(al_id) );

CREATE TABLE tbl_image ( im_id INT NOT NULL AUTO_INCREMENT, im_album_id INT NOT NULL, im_title VARCHAR(64) NOT NULL, im_description TEXT NOT NULL, im_type VARCHAR(30) NOT NULL, im_image VARCHAR(60) NOT NULL, im_thumbnail VARCHAR(60) NOT NULL, im_date DATETIME NOT NULL, PRIMARY KEY(im_id) );

Directory Layout

The images directory is where we kept all of the images. The image icons are stored in the thumbnail sub-directory uder the gallery. Please remember to set write access to the album, gallery, and thumbnail directories otherwise the gallery script will not be able to save the images.

Config.php Source : Open config.doc There are some constants in the config file that you should change :config file  ALBUM_IMG_DIR, GALLERY_IMG_DIR These are the absolute path to the images directories  THUMBNAIL_WIDTH The PHP script will create a thumbnail ( icons ) for each image that you upload. In addition when you add an album image that image will also resized automatically.

One more note. If you want to test this gallery on your own computer please make sure you already have GD library installed. To check if GD library is installed on your system save the following code and run it.

Image Gallery Administration Page Login Source : open login.doc

Logout.php

Admin Page Layout Source : open admin-index.php

Admin : Add New Album This is a very simple form where you can enter the album name, description and image. After you click the "Add Album" button the script will do the followings :  Save the album image, resize it if necessary  Save the album information to database

Interface add new album Source : open add-album.doc

Admin : Album List

Modify & Delete Album Source : open modify-album.doc

Delete Album The code for deleting an album is located in the index.php file. The code flow is like this :  Get the album id  Make a query to get the name of that album and the thumbnail filename. Print an error message if the album doesn't exist  If the album exist get images file name and delete the images plus the album icon  Delete the album data and the images from the database

Source delete : lihat admin-index.doc //... some code on top if (isset($_GET['deleteAlbum']) && isset($_GET['album']) ) { $albumId = $_GET['album']; // get the album name since we need to display // a message that album 'foo' is deleted $result = mysql_query("SELECT al_name, al_image FROM tbl_album WHERE al_id = $albumId")

Album List