I am not going to argue about the choice of a template engine against only PHP. I choose not to use a template engine, like Smarty, because I would like to learn how to prop
Just use alternative PHP syntax for if/for/foreach control language constructs which are designed specifically for this purpose:
Users
0): ?>
Id
First Name
Last Name
Id); ?>
FirstName); ?>
LastName); ?>
No users in the database.
I also suggest creating view helpers for HTML outputs that are very similar and use them instead of having repeated HTML code.