1
fdj
html, php or?
  • 2003/12/13 11:00

  • fdj

  • Just popping in

  • Posts: 51

  • Since: 2002/9/19


Hello i would like to make a customized block to display a random picture...

here is my code :

<img src='http://www.mysite.org/images/random/<?php echo rand(1,20) ?>.jpg width='78' height='78' align='left'>

if I choose php for the block it doesn't display the pictures .

How can i do this?

thx a lot

2
robekras
Re: html, php or?
  • 2003/12/13 12:55

  • robekras

  • Documentation Writer

  • Posts: 187

  • Since: 2002/12/10


If you have a php block you have to write the following:

echo "<img src='http://www.mysite.org/images/random/";
echo rand(1,20);
echo ".jpg' width='78' height='78' align='left'/>";

Login

Donat-O-Meter

Stats
Goal: $15.00
Due Date: Sep 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $15.00
Make donations with PayPal!