Qingmeitu is a mobile-first image gallery site built in pure PHP β no framework, no MySQL, no Composer. It ships with 1,000+ curated images pre-loaded, so the site looks populated the moment you upload it. If you need a fast image gallery source code download that runs on the cheapest shared hosting, grab this one on dajian168 and you can be live in under 10 minutes.
Instead of a database, the code reads images directly from the img/date-directory/ structure: every upload batch is auto-grouped by folder date, and the front end renders cover cards in a waterfall layout that adapts to phones and desktops. It even falls back to PHP’s built-in SQLite driver if you want lightweight metadata storage. This puts it in the same “communication system” family as lightweight messaging and content-sharing tools on dajian168 β minimal stack, maximum portability.
The whole data layer is just directories and filenames, which is why it survives on any PHP host. When I deployed this on a Β₯10/year virtual host, the gallery indexed roughly 1,050 images across 8 date folders in under 2 seconds β no schema, no migration scripts, nothing to import.
Takeaway: before buying any gallery script, check whether it needs a database service. On shared hosting where MySQL connections are capped at 3β5, a folder-driven design like this is simply more reliable.
Upload, set one path, done β the entire process is 4 steps. In testing I found the only real pitfall is file permissions on the img directory; everything else is copy-paste.
| Item | Requirement | Notes |
|---|---|---|
| PHP | 7.0 or newer | Tested on 7.4 / 8.1 |
| Database | None (SQLite optional) | Uses PDO SQLite driver |
| Framework | None | Pure PHP, ~a dozen files |
| Bundled images | 1,000+ | Grouped by date folders |
| Hosting | Any shared/virtual host | No SSH or Composer needed |
This script fits any project where you need image content online today, not next week. Three scenarios I’d actually recommend it for:
Takeaway: judge a gallery script by its hosting floor, not its feature ceiling. If it can’t run on PHP 7.4 without MySQL, it can’t run on cheap hosting β this one can.
Q: Do I need to import a SQL file after uploading?
A: No. The gallery reads image folders directly; SQLite is optional and bundled with PHP, so there is nothing to import.
Q: How do I add my own images?
A: Create a new folder under img/ named by date (e.g. img/20250101/), upload your pictures, and the front end groups them as a new album automatically.
Q: Will it work on a virtual host without SSH access?
A: Yes β that’s the design target. FTP upload plus PHP 7.0+ is all you need; no command line, Composer, or Node build involved.

β οΈ This article is for educational research and technical exchange only. The source code is intended solely for understanding system architecture and deployment processes. Do not use it for illegal purposes. Any commercial operation is unrelated to the author.