php-windows Digest 24 Aug 2003 04:59:45 -0000 Issue 1884

Topics (messages 21220 through 21222):

Re: please help with table
        21220 by: H Marc Bower

Thanks all
        21221 by: Thomas Edward Lawrence

please help with table again
        21222 by: Thomas Edward Lawrence

Administrivia:

To subscribe to the digest, e-mail:
        [EMAIL PROTECTED]

To unsubscribe from the digest, e-mail:
        [EMAIL PROTECTED]

To post to the list, e-mail:
        [EMAIL PROTECTED]


----------------------------------------------------------------------
--- Begin Message ---
Give this a go:

<?php
 $row = 0;
 $col = 0;
 echo "<TABLE border=1>";
 while($row < 3)
 {
  $row++;
  echo "<TR>";
  while($col < 5)
  {
   $col++;
   echo "<TD>Row ".$row." Column ".$col."</TD>";
  }
  $col = 0;
  echo "</TR>";
 }
 echo "</TABLE>";
?>

Hope that helps,

Marc

----- Original Message ----- 
From: "Thomas Edward Lawrence" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Saturday, August 23, 2003 12:13 PM
Subject: [PHP-WIN] please help with table


> When I write this , it will echo 1 column with 5 rows , but I want it echo
5
> columns with 3 row , there are 5 colums(td) in every row(tr) , how I must
> write  ,
> please show me , thank you .
>
> <table border="1" width="100%">
> <?
> $i = 0 ;
> while ($i < 5)
> {
> $i++ ;
> echo "<tr><td>$i</td></tr>" ;
> }
> ?>
> </table>
>
>
>
>
> -- 
> PHP Windows Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>



--- End Message ---
--- Begin Message ---
so good ,  thank you , thanks so muck

...........................
"H Marc Bower" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Give this a go:
>
> <?php
>  $row = 0;
>  $col = 0;
>  echo "<TABLE border=1>";
>  while($row < 3)
>  {
>   $row++;
>   echo "<TR>";
>   while($col < 5)
>   {
>    $col++;
>    echo "<TD>Row ".$row." Column ".$col."</TD>";
>   }
>   $col = 0;
>   echo "</TR>";
>  }
>  echo "</TABLE>";
> ?>
>
> Hope that helps,
>
> Marc
>
> ----- Original Message -----
> From: "Thomas Edward Lawrence" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Saturday, August 23, 2003 12:13 PM
> Subject: [PHP-WIN] please help with table
>
>
> > When I write this , it will echo 1 column with 5 rows , but I want it
echo
> 5
> > columns with 3 row , there are 5 colums(td) in every row(tr) , how I
must
> > write  ,
> > please show me , thank you .
> >
> > <table border="1" width="100%">
> > <?
> > $i = 0 ;
> > while ($i < 5)
> > {
> > $i++ ;
> > echo "<tr><td>$i</td></tr>" ;
> > }
> > ?>
> > </table>
> >
> >
> >
> >
> > --
> > PHP Windows Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
> >
>
>

--- End Message ---
--- Begin Message ---
I want  it echo 5 columns with 3 row , but it also echo numbers which
increase to follow columns like this  , how I must write  , please show me
again , thank  you .

1    2    3    4    5
6    7    8    9    10
11    12    13    14    15

--- End Message ---

Reply via email to