Simple PHP Photo Gallery

2020, by www.raffia.ch, hjke, Version 1.1

PHP-Version >= 5.3

About

Reads and displays all image files (jpg, png, gif) from a given directory, using jQuery and Lightbox2.

  • THIS SCRIPT IS FREE "AS IS" AND WITHOUT ANY WARRANTY
  • You may copy, use and redistribute it without any restriction
  • Give credit and place a backlink in your project!

Installation

Upload the gallery folder and its content onto your webspace. Open the corresponding URI (www.yoursite.net/gallery/) in your webbrowser. Image directory name may be changed editing the PHP script: glob("yourphotos/*").

Integration In Your Website

The PHP variable $gallery contains all HTML image items, each embedded in a link. It may be printed inside the HTML context of your existing website. See the the HTML-template file as an example.