flogr is a php script that will display your public flickr photos in a customizable photo gallery you host on your website. If you use flickr but want to have a different look and feel for your photo gallery you may like flogr.
✨ Now fully compatible with PHP 8.1! This version includes modern security features, free OpenStreetMap integration, and comprehensive PHP 8.1 compatibility fixes.
Go on and take it for a spin.
- Customizable photoblog interface for your flickr photos
- Display all flickr photos, only photos with certain tags or only certain photosets
- Displays photo details, EXIF data, tags, geo location, and photo comments
- Thumbnail viewer displays photos by date taken, photoset, and tag
- Embedded Slimbox photo slideshow
- Map view of your geo tagged photos
- Flickr tag cloud page
- RSS 2.0 support
- PHP 7.4+ (PHP 8.0+ recommended)
- Apache or Nginx web server
- Flickr account and API key
-
Download and unpack the zip locally
-
Get your Flickr API Key
- Visit https://www.flickr.com/services/api/misc.api_keys.html
- Apply for a non-commercial API key
- Copy your API key
-
Configure Environment Variables
# Copy the example environment file cp .env.example .envEdit
.envand add your Flickr API key:FLICKR_API_KEY=your_flickr_api_key_here
-
Configure Flogr Settings
- Enter your Flickr user ID on line 27 of
admin/config.php - You can lookup your Flickr ID at http://idgettr.com/
/** * Your Flickr user id and/or group id * * Note: A flickr id (not name) is needed. */ OPTIONAL_SETTING('FLICKR_USER_ID', 'YOUR-FLICKR-USER-ID');
- Enter your Flickr user ID on line 27 of
-
Optional: Configure Caching
For better performance, you can enable caching in your
.envfile:MySQL Cache:
CACHE_SQL_USER=your_db_user CACHE_SQL_PASSWORD=your_db_password CACHE_SQL_SERVER=localhost CACHE_SQL_DATABASE=flogr_cache
File System Cache:
CACHE_PATH=/tmp/flogr_cache
-
Set Correct Permissions
# Protect your .env file chmod 600 .env # If using file system cache mkdir -p /tmp/flogr_cache chmod 755 /tmp/flogr_cache
-
Upload to your webserver
- Upload the contents to your webserver (e.g.,
http://foo.com/bar) - IMPORTANT: Ensure
.envis NOT accessible via web browser
- Upload the contents to your webserver (e.g.,
-
Verify Installation
- Visit your site in a browser
- You should see your Flickr photos displayed
This version includes critical security fixes:
- Removed hardcoded API credentials
- Added input validation and sanitization
- Implemented XSS protection
- Added security headers
- Fixed path traversal vulnerabilities
See SECURITY.md for detailed security information.
"FLICKR_API_KEY not set" error:
- Ensure
.envfile exists and containsFLICKR_API_KEY=your_key - Check file permissions on
.env(should be readable by web server)
Photos not displaying:
- Verify your Flickr API key is correct
- Check that your Flickr user ID is set in
admin/config.php - Ensure your Flickr photos are set to public
Performance issues:
- Enable caching (MySQL or file system)
- Consider using a CDN for static assets
The best way to get your questions answered is emailing me mikecarruth@gmail.com
flogr is free to use. Want to share the love? You can by feeding my caffeine addiction or buying me a beer. Thanks!




