I've got some code that I am
creating that creates a table with
a loop. and it works fine for what
it is, but my question is how do I
compensate for rows that aren't divisible
by 5 ? i.e. the empty cells at the table.
additionally if it ends on a complete row
(divisible by 5) I end up with an
check to see if you need that closing /tr
That is the if statement after you're loop...
I hope this helps.
-jack
-Original Message-
From: Jerry Lake [mailto:[EMAIL PROTECTED]]
Sent: Thursday, April 26, 2001 2:32 PM
To: [EMAIL PROTECTED]
Subject: [PHP] cell iterations in loop
I've got
]]
Sent: Thursday, April 26, 2001 1:18 PM
To: [EMAIL PROTECTED]; Jerry Lake
Subject: RE: [PHP] cell iterations in loop
I'm a little unclear as to what you're trying to do, but here's my
interpretation:
problem 2: if it ends on a complete row...
solution: put the echoing of the first and last tr's
://www.pacifier.com
-Original Message-
From: Jack Dempsey [mailto:[EMAIL PROTECTED]]
Sent: Thursday, April 26, 2001 1:18 PM
To: [EMAIL PROTECTED]; Jerry Lake
Subject: RE: [PHP] cell iterations in loop
I'm a little unclear as to what you're trying to do, but here's my
interpretation:
problem 2
- Original Message -
From: Jerry Lake [EMAIL PROTECTED]
Date: Thursday, April 26, 2001 4:54 pm
Subject: RE: [PHP] cell iterations in loop
Thanks, that worked with the removal
of the first if clause for part 2 of
my question, as far as part one, I will
try to explain better. if you view the
chunk
]
Subject: Re: RE: [PHP] cell iterations in loop
ok, again, trying to understand blank space...but, try this:
if you print out td/td you'll get something i think you're referring to
as blank space...
try using a nonbreaking space in there...either nbsp; or a space in the
code; this will force
: Thursday, April 26, 2001 5:20 pm
Subject: RE: RE: [PHP] cell iterations in loop
Right, I understand that
if I use td/td it is blank space
if I use td /td it is an empty cell
right now $length is set at 42 (this is arbitrary)
and there needs to be two empty cells at the end of
the last row
:26 PM
To: Jerry Lake
Cc: [EMAIL PROTECTED]
Subject: Re: RE: RE: [PHP] cell iterations in loop
ah, i got it...
ok, try this:
$length is arbitrary...
$x is your counter...
do the loop as before, but each time through the loop, $loopcount++;
So, if you do the loop 5 times, $loopcount == 5
8 matches
Mail list logo