how to write html in php code example
Example 1: inline php in html
<body>
Hello, today is <?php echo date('l, F jS, Y'); ?>.
</body>
Example 2: can i write php code in html file
<div>
<?php echo "This is printed by PHP"; ?>
</div>
<div>
<?php $sum = 5+2; echo $sum; ?>
</div>