![]() |
|
|
|||||||
![]() |
|
|
Thread Tools | Rate Thread |
|
|
PM User | #1 |
|
New Coder ![]() Join Date: Jan 2004
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
![]() |
Break rows in table
I am a neewbie. Recently time which I have begun to program in PHP with MySQL, and I need to solve a problem.
I have a table that relates all the registries of a table in a database MySQL which begin by a letter, ordered of ascending form. Table HTML must consist of limitless rows and 4 columns I have all the code, unless not like inserting tags </tr><tr> each 4 rows. Please, somebody can help me? I stick the code fragment so that it is understood well... PHP Code:
PHP Code:
http://www.---.com/letras.php?letra=A I summarize. I need the data appear in a table that has 4 columns. I always need that each 4 results this code is inserted: </tr><tr> in case that there is more than 4 results. Now in my script has a <td></td> for each entry in the database. But i wish that each 4 entries has </tr><tr>, so that the table only has four columns. Thanks (i speak english only a litte. Excuse me) |
|
|
|
|
|
PM User | #2 |
|
Master Coder ![]() ![]() Join Date: Jul 2002
Posts: 6,589
Thanks: 0
Thanked 0 Times in 0 Posts
![]() |
this is not a mysql issue. it's a PHP question. this thread contains code and links to create a table with 3 columns out of your recordset. Just change the 3 to 4 for your case
http://www.codingforums.com/showthread.php?t=50422
__________________
Posting guidelines I use to see if I will spend time to answer your question : http://www.catb.org/~esr/faqs/smart-questions.html |
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Rate This Thread | |
|
|