PHP problem

Questions about programming languages and debugging
Post Reply
User avatar
ayu
Staff
Staff
Posts: 8109
Joined: 27 Aug 2005, 16:00
18
Contact:

PHP problem

Post by ayu »

This is just a thing i am testing from my book...but it is not working

Code: Select all

<?php for($upp=1,$ned=7;$ned>0;$upp++,$ned--) { ?>
<font face="Arial" size="<?php $upp; ?>"> 
<?php echo $ned; ?>
</font><br>
<?php }  ?>

It doesn't give me larger numbers...just ...numbers of the same size : /

EDIT: Solution:

Code: Select all

<?php for($upp=1,$ned=7;$ned>0;$upp++,$ned--) { ?>
<font face="Arial" size="<?php echo $upp; ?>">
<?php echo $ned; ?>
</font><br>
<?php }  ?>
"The best place to hide a tree, is in a forest"

Post Reply