MySQL Help

From: Date: Thu, 25 Sep 2003 03:58:29 +0000
Subject: MySQL Help
Groups: php.windows 
Request: Send a blank email to php-windows+get-21547@lists.php.net to get a copy of this message
Hey, I am working on a new script that allow's the use to insert upto 10 extra image per item in the catalog. What i need to do is print 5 images per line. I need to know how i can print 5 image per <td> field the code i currently have is this $num_items = amount user wants; $num = $num_items / 2; if ($num_items == "10") { for ($i=0;$i<$num;$i++) { echo "<img src="$img_name" size="100" width="100"><br>Click Image To See Preview"; } for ($i=5;$i<$num_items;$i++) { echo "<img src="$img_name" size="100" width="100"><br>Click Image To See Preview"; } } as you see this is really only good if there is 10 images but some products have 3 some have 7 is there a way i can do this so it always put's the same amount of images per line when the number is over 5 thanks Dean "The Insane Guy" Hayes Mystical Web Designs http://www.mystical-sector.com <-- I design and i redesign but still i never designed true beauty like you --> _________________________________________________________________ Hot chart ringtones and polyphonics. Go to http://ninemsn.com.au/mobilemania/default.asp

« previous php.windows (#21547) next »