Overclock.net › Forums › Software, Programming and Coding › Coding and Programming › Web Coding › Random Pictures in HTML/PHP
New Posts  All Forums:Forum Nav:

Random Pictures in HTML/PHP - Page 2

post #11 of 14
Papa John's yummm
    
CPUMotherboardGraphicsRAM
E6750 at 3.6GHz MSI P6N SLI Platinum eVGA 8800GTS 512 Mb |750|1885|2130| Crucial Ballistix 2GB PC6400 @ 930 5-5-5-15 
OSMonitorKeyboardPower
Vista SP1 ViewSonic G810 21" CRT Saitek Eclipse OCZ GameXStream 600W 
CaseMouseMouse Pad
CM 690 Logitech Mx-518 Gateway 
  hide details  
Reply
    
CPUMotherboardGraphicsRAM
E6750 at 3.6GHz MSI P6N SLI Platinum eVGA 8800GTS 512 Mb |750|1885|2130| Crucial Ballistix 2GB PC6400 @ 930 5-5-5-15 
OSMonitorKeyboardPower
Vista SP1 ViewSonic G810 21" CRT Saitek Eclipse OCZ GameXStream 600W 
CaseMouseMouse Pad
CM 690 Logitech Mx-518 Gateway 
  hide details  
Reply
post #12 of 14
Quote:
Originally Posted by xShiFTx View Post
Papa John's yummm
Haha

I just went to google images and grabbed the first few results for "logo" that were interesting.
Morpheus Mini
(7 items)
 
  
CPUMotherboardGraphicsRAM
i7-6700T SN970 GTX 960 Crucial CT102464BF160B 
Hard DriveOSAudio
Samsung 850 Evo M.2 Windows 10 Pro MOTU Audio Express 
  hide details  
Reply
Morpheus Mini
(7 items)
 
  
CPUMotherboardGraphicsRAM
i7-6700T SN970 GTX 960 Crucial CT102464BF160B 
Hard DriveOSAudio
Samsung 850 Evo M.2 Windows 10 Pro MOTU Audio Express 
  hide details  
Reply
post #13 of 14
A dynamic way to do it (keeping the filenames you want) is like this:
Code:

<?php

$pictures = array("Frag.gif","Cat.gif","Cheese.gif","Puppy.png","Zomg.jpeg"); //Frag.gif is Pictures[0] of the pictures array, Cat.gif is Pictures[1] and so on...
?>
<img src="http://site/images/<?php echo($pictures[rand(0, count($pictures))]); ?>">
If you ever want a new image, just add the filename to the pictures array.
e.g.
Code:
$pictures = array("Frag.gif","Cat.gif","Cheese.gif","Puppy.png","Zomg.jpeg","Somethingnew.png");
post #14 of 14
Thread Starter 
Wow thanks alot Lyokohack i'll try both ways
Kopisaurus
(13 items)
 
  
CPUMotherboardGraphicsRAM
Intel 2500k @ 5ghz 1.395v Gigabyte P67A-UD3P-B3 ATI HD6950 2GB (flashed --> 6970) 16GB Gskill Sniper 1600mhz 
Hard DriveOptical DriveOSMonitor
500gb WD Black / 2x 1TB WD Black RAID1 LG DVD/RW Super Multi Windows 7 Enterprise x64 ASUS ML239H 23" LED  
KeyboardPowerCaseMouse
Logitech G15 (modded) Corsair TV750W V2 Lian-Li Lancool PC-K62B Logitech G5 
  hide details  
Reply
Kopisaurus
(13 items)
 
  
CPUMotherboardGraphicsRAM
Intel 2500k @ 5ghz 1.395v Gigabyte P67A-UD3P-B3 ATI HD6950 2GB (flashed --> 6970) 16GB Gskill Sniper 1600mhz 
Hard DriveOptical DriveOSMonitor
500gb WD Black / 2x 1TB WD Black RAID1 LG DVD/RW Super Multi Windows 7 Enterprise x64 ASUS ML239H 23" LED  
KeyboardPowerCaseMouse
Logitech G15 (modded) Corsair TV750W V2 Lian-Li Lancool PC-K62B Logitech G5 
  hide details  
Reply
New Posts  All Forums:Forum Nav:
  Return Home
  Back to Forum: Web Coding
Overclock.net › Forums › Software, Programming and Coding › Coding and Programming › Web Coding › Random Pictures in HTML/PHP