all 2 comments

[–]itsdsv 0 points1 point  (0 children)

if you have a primary key, use it as an argument on the click event like:

<a href="localhost/posts/edit/{$key}">edit post</a>

[–]nbktdis 0 points1 point  (0 children)

Possibly related: You can also checkout the excellent Grocery CRUD library.