Alex Black ...
> <input type="text" name="hello" size="20" value="<?=$value?>">
>
> is really not that much harder to write.
>
> html people can ignore it, php can find their code, and those that know both
> can reap the benefits.
>
> what about loops?

You mean that this code


<?
connect_to_database();
parse_query();
execute_query();

echo "<TABLE>";

while (fetch_row_from_query())
    {
    $output = data_from_fetched_row();
    $more_output = more_data_from_fetched_row();

    echo "<TR><TD> $output </TD><TD> $more_output </TD></TR>";

    }
echo "</TABLE>";
?>



would be better if it were written this way? :


<?
connect_to_database();
parse_query();
execute_query();
?>
<TABLE>
<? while (fetch_row_from_query()) : ?>

<?    $output = data_from_fetched_row();
    $more_output = more_data_from_fetched_row();    ?>

    <TR><TD><?=$output?></TD><TD><?=$more_output?></TD></TR>

<? endwhile; ?>
</TABLE>



I _personally_ prefer the upper implementation, as all my web developing team (that 
is, only me :-) know both PHP and HTML and don't
like the code to be *plagued* of <? ?> <? ?> <? ?> as in above example.



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to