search

Home  >  Q&A  >  body text

php $s is written after the if statement

<?php

$s=0;

echo '<table width="800" border="1">';

while ( $s<100){

 

  if($s ==0){  

                                                                              using   use using   using   using   using     using ‐ ‐ ‐ echo '<tr>'-- s.'</tr>';

                                                                                                                                                                                        s.'</td>';

$s ;

}echo '</table>';

?>

Why does 0102030405060708090

appear when written like this?

G°2111 days ago1147

reply all(1)I'll reply

  • Libra

    Libra2019-04-27 17:15:51

    The reason for echo '<tr>'.$s.'</tr>'; is because you directly output the value in tr after each $s%==0. The tr output content will be displayed directly above the table. Normally, the <tr> set of <td> tags will be used.



    reply
    0
  • Cancelreply