I am deploying a small PHP + MySQL service to my client and would like to know what is the proper way to set up the database:
CREATE
scripts in my PHP to run during the "init phase"? Do hosting providers even allow PHP to create tables?It's a really small site, one tiny info page and one web service page for fetching data from the database.
I usually offload all deployment tasks into an install script. This way you can deploy in a matter of seconds, and can repeat if necessary. I do not know of a way to restrict scripts from database modifications (other than mysql user permissions, which will typically be defined by you)