- Audio & Multimedia
- Business
- Communications
- Desktop
- Development
- Education
- Games
- Graphics
- Home & Hobby
- Network & Internet
- Screen Savers
- Security & Privacy
- Servers
- System Utilities
- Web Development
- AnyMP4 DVD Ripper for Mac
- FoneLab Data Retriever
- Recupero File Cancellati
- AnyRec Video Repair
- Aiseesoft Mac FoneLab
- SSuite NetSurfer E-Gamer x64
- USB Disk Undelete
- Verwijderde Bestanden...
- Business Purchase Order
- Secure Eraser
- Atlantis Word Processor
- FrontSketch
- Apeaksoft DVD Creator for Mac
- UltraFileSearch Std
- Pen Drive Recovery Free
- ADRC Data Recovery Tools
- avast! Antivirus
- Revo Uninstaller
- Java Runtime Environment
- AVG Anti-Virus Free Edition
- GOM Media Player
- RegSeeker
- IrfanView
- CPU-Z
- Malwarebytes Anti-Malware
- Spybot Search & Destroy
- Skype
- µTorrent
-
2Printer 5.5
Enables you to print any type documents or files in bath mode one after another specifying the paper size and without any...
-
Vivaldi for MacOS 6.6
No ad browser and uses minimum memory, takes very less time to load, some unique features added like notes containing...
-
Win PDF Editor 3.6.3
Editing PDF documents was like nightmare for me but when I am suggested by one of colleagues I tried this and found that...
-
Serial to Ethernet Connector 9.0
It can successfully turn your computer to a terminal server so that any device connected to the com port will be...
-
ShutUp10 1.4.1388
This software will let you take the full control over your windows 10 and decide which program to start automatically or...
-
TeraCopy 3.26
Copies files seamlessly from source to target location, also detects errors while transferring and rectifies it.
-
Ulysses for Windows 2.7.11
Writing application with most of useful features that a standard word processor may offer like markdown, emerging to...
-
InjuredPixels 4.0
It will repair the damaged pixels of the display unit so that it can still be usable for some more days instead of buying...
-
DrvInfo 1.2.0.2016.0
The software will show you the details of a drive as soon as it is inserted into the port whether it is a floppy, flash...
-
Unreal Commander 3.57
Can see the files in windows. You may copy, cut and paste right from there or upload to server directly.
Web Development / Other / ResizedRandomImage 1
ResizedRandomImage 1
Advertisement
Advertisement
ResizedRandomImage 1 Description
This PHP script is self explanatory, including comments, recommendations and instructions.
This PHP script is self explanatory, including comments, recommendations and instructions. It displays a random image from a directory, always within a max width and/or length and maintaining its original ratio between width and length and calculated before displaying it. It includes comments to make it easier to understand and implement, no php knowledge is needed. It has only 3 variables: $path = name of the directory where to put the images to display (in the example: 'aa_Images/') // Indicate meximum height of the image to display $max_height = max expected height (in the example: 125) $max_width = max expected width (in the example: 200) Please have in mind that filenames should not contain blank spaces! eventhough it may work in some cases. Please also have in mind that the original images are not changed in any way, they are just displayed in a different size so take care with their size when putting them in the directory where to pick them from as, if really large, they may penalize your page with a long time to download it. I am using it to display random images to give my visitors the sensation that the page has changed. You can also use it to display funny images which would give your visitor an incentive to visit your page to see what's new without any action from your side to do any change. Hope you find it useful as I did and please don't forget to post your comments and small utilities and developments as they can be useful to others. Internet is developed based on the sharing principle. You can see it working at: homepage Here we left 5 images of different sizes to see the functionality. You can contact me at email Good luck! Fred email www.learngolfvideos Twitter: @LearnGolfVideos Facebook: fred.learngolfvideos or Learn-Golf-Videos/432483040122943
OS: Linux, Unix, Windows 7, Mac Os X, Win7 x32, Win7 x64, Win98, WinServer, WinXP
System Requirements: any php interpreter
Tags: Php Utilities - Freeware - Display Resized Random Image - Learngolfvideos Com - Golf Videos