Installing ImgURL Image Hosting
Machine-translated (anthropic, claude-haiku-5-5) from the Chinese original. Read the original in 中文
Contents
Preface
The previous article covered solutions for Sina image hosting failures. But our many bloggers were unwilling to remain constrained by Sina and at the mercy of its whims, which affected their blogs. So this article was written specifically to keep bloggers' image assets safe!
ImgURL is a simple, pure image hosting program, developed with PHP + SQLite 3.



Key Features
- Supports drag-and-drop upload, multi-image upload, Ctrl + V paste upload, and URL upload
- Supports image cropping and automatic thumbnail generation
- Limits the number of uploads by visitors
- Image compression / batch compression
- Image adult-content detection / batch detection
- API support
- Online update
- External storage
Environment Requirements
- PHP >= 5.6
- PDO_SQLite
- GD2
- ImageMagick
- fileinfo
- pathinfo
Main Content
Without further ado, let's get started.
Configuring Pseudo-Static Rewrites
Nginx
location / {
try_files $uri $uri/ /index.php?$query_string;
}
location ~* \.(db3|json)$ {
deny all;
}
location ~* ^/(temp|upload|imgs|data|application|static|system)/.*.(php|php5)$ {
return 403;
}Add the above rules into the Nginx server block, and don't forget to reload Nginx once.
Apache
The .htaccess rules are included by default, so no setup is needed.
Installation
Visit https://github.com/helloxz/imgurl/releases to download the latest source code, and extract it to the site root directory. (Mind the directory permissions, mind the directory permissions, mind the directory permissions.)
Visit your domain http(s)://domain.com/install/?setup=1 and follow the prompts to install. If the environment check fails, please resolve the environment issues yourself.
Installing fileinfo & ImageMagick
If you have not installed them, read on.
(The demonstrations all use the BT Panel.)
In the BT Panel backend - Software Management - find the PHP version for your site - Settings for PHP - Install Extensions - tick fileinfo and imagemagick, as shown in the screenshot below.

PS: ImageMagick is not mandatory. This operation requires your ImgURL version to be v2.1 or above.
Final Words
Wishing you a pleasant experience. Hehe, do share generously!
Comments