I would not like to echo this code because I need to match the other syntax in my .php. How would I get this to work. I've looked everywhere and can't find a solution.
<? if (mysqli_num_rows($result) > 0): ?>
// output data of each row
<? while($row = mysqli_fetch_assoc($result)): ?>
<center><b><p>Order ID: " . $row['ID'] . "</p></b></center><br>
<center><b><p>Order Total: " . $row['total'] . "</p></b></center><br>
<center><b><p>Order Status: " . $row['status'] . "</p></b></center><br>
<center><b><p>Payment Status: " . $row['payment'] . "</p></b></center><br>
<? endwhile ?>
mysqli_close($conn);
<?php endif; ?>
What is the problem with this code?