Skip to content

4kercc/php-random-img

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PHP Random Image

this is a simple script to select images randomly from the folder you set, you can use it on your blog background, or your personal site, or anything you like =v=

Installation

just put all the files into your web folder (make sure you have PHP environment installed), then you can add your favorite images into imgs folder if you didn't change the default config.

Configure the script

the default image folder is named as imgs if you want to configure the default seeting, please refer to config.inc.php to modifiy your seetings.

Supported arguments:

  • IMG_DIR - the relative path for your images folder from your web server.
  • IMG_EXTENSIONS - the supported image file extension for your images.
  • IMG_NO_REPEAT_CURRENT - if set to true the next randomly selected image won't be same to the currently selected image, if set to false will ignore the currently selected image for next random select (so the repetitive selected image may occur).

About

一个简单的随机选图片的脚本

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages