is there anyone who can give me a sample on how to loop the 'div'??
I am Creating an eCommerce website and in my homepage I want to display the image of the product and its information. But I don't know how to upload an image and display it to a web browser using 'php' and 'mysql'.
Here is my database.
tbl_product
productID image name description price
Can you Help me?
You need to put more effort into your question. It's broad. Although, if all you want to do is create a <div>
within a while
loop, then something like the following will work:
<?php while(YOUR_CONDITION): ?>
<div>
</div>
<?php endwhile; ?>
Fro e.g you want to print a div 10 times then.
<?php
$i =0;
while($i<10): ?>
<div>
</div>
<?php
$i++;
endwhile; ?>