![]() |
preg_replace an image
I want to output a random number (1 to 40) and to output an image associated with the number.
I have sorted the first part with... PHP Code:
Thankyou |
If your images are names 1.gif, 2.gif etc:
Code:
$img = '<img src="path/to/images/'.mt_rand(1, 40).'.gif" alt="" />'; |
All times are GMT. The time now is 01:12 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|