(( Posting this response for another member ))
The typical way I've seen this done is to set up an actual Access Control List (ACL) and then before each request, check to see if they have access to complete the request they want. So instead of storing a unique username to an item in the database, after login, you would just set an access level or cache their ACL paths. Then upon each subsequent request where the session is active, you can quickly check the ACL for that permission. So it might look something like:
<? php if ($aclObject->hasPermission('my_model_name/delete'): ?>
<li class="delete"><a href="delete.php?id=<?php echo "<my_model_entry_id>"; ?>">Delete</a></li>
<?php endif; ?>
<?php
if ($aclObject->hasPermission('my_model_name/delete')) {
// Attempt to delete the row from the database
}
It's a bit of a burden to build the ACL; however, it provides you greater flexibility in how you deal with permissions. You can be as strict as you want going down to the row level, or you can be as loose as you want and just say "They can do whatever they want within <my_model_name>".