Projects / Portfolio Site - sathishkannan.com / Architecture Decision
Config file for text, database for structured profile data
When I added a profile management system to the admin panel, I had to decide what goes in the database and what stays in a file.
The answer I landed on: if you need a UI to manage it, put it in the database. If you just need to edit a line of text occasionally, a PHP config file is enough.
Career timeline entries need CRUD — add a new role, edit the description, reorder. That belongs in MySQL with an admin interface.
The homepage hero copy — two paragraphs and a "current focus" label — doesn't need a table, a form, and a save button. It needs a file you open and edit directly. content.php is that file.
The risk is that content lives in two places. I accepted that tradeoff because the alternative — admin forms for every piece of text on the site — adds complexity without adding real value.
The rule I use: if updating it without a developer feels painful, put it in the database. If a text editor is fine, keep it in a file.