Jump to content


Photo

Looking for a good tutorial...


  • Please log in to reply
5 replies to this topic

#1 jwwceo

jwwceo
  • Members
  • PipPipPip
  • Advanced Member
  • 212 posts

Posted 26 August 2006 - 09:48 PM

I am looking for a tutorial on building a product gallery where products are diplayed in a grid format, like this www.bustedtees.com. I mostly need to know how to get the search results to display 4 across. Right now, I can just get them to make a big list, where each entry is a row in a table....

Are there any tutorials on this online anywhere..or anyone have any tips on how to do this....

#2 ronverdonk

ronverdonk
  • Members
  • PipPipPip
  • Advanced Member
  • 277 posts
  • LocationNetherlands

Posted 26 August 2006 - 10:21 PM

Make a table with 4 <td> per row, like this:

<table width='100%'>
<tr><td><img src=image1></td><td><img src=image2></td><td><img src=image3></td><td><img src=image4></td></tr>
<tr><td><img src=image1></td><td><img src=image2></td><td><img src=image3></td><td><img src=image4></td></tr>
</table>
Only make sure the size of 4 images fit onto one table row.

Ronald  8)
RTFM is an almost extinct art form, it should be subsidized.

#3 jwwceo

jwwceo
  • Members
  • PipPipPip
  • Advanced Member
  • 212 posts

Posted 26 August 2006 - 10:25 PM

The HTML is easy....

I need tips on the php part...

#4 AndyB

AndyB
  • Staff Alumni
  • Advanced Member
  • 5,465 posts
  • LocationToronto

Posted 26 August 2006 - 10:29 PM

I need tips on the php part...


start a new table row
set a column counter to zero
create a table data cell, insert content, close table data cell
increment the column counter
if the column counter=4 close the table row
continue ...
Legend has it that reading the manual never killed anyone.
My site

#5 ronverdonk

ronverdonk
  • Members
  • PipPipPip
  • Advanced Member
  • 277 posts
  • LocationNetherlands

Posted 26 August 2006 - 10:32 PM

Would be a lot easier when you explained what the problem is. Just "I need tips on the php part..."doesn't say very much on what exactly you are looking for.

Ronald  8)
RTFM is an almost extinct art form, it should be subsidized.

#6 jwwceo

jwwceo
  • Members
  • PipPipPip
  • Advanced Member
  • 212 posts

Posted 26 August 2006 - 11:31 PM

Thank you Andy...that was way easier than I thought it would be....




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users