PHP Booosta 3 Tutorial
PHP Booosta 3 Tutorial
Creating basic files
Now we have a web application that can already deal with users and
privileges. But now we want to manage the data in our previously
created tables. For this reasons we need PHP scripts and templates. As
these files always look similar for the basic tasks like creating,
editing and deleting records it would not make much sense to type them
into an editor manually every time. It would be easier to let the
framework do this dump work and autocreate these files.
Luckily there is a module for that purpose. And it can be used by the
web application itself in the admin section (i. e. if you are logged in
as an admin user). For security reasons this works only, if a file
named ENABLE_MKFILES is present in your web root. This is the case
after installation. When you have created all your files, you shold
delete this file.
For creating files now, click on "Create app files" in the main menu left:
On the following page you have to select if the files you created are
for admin users or normal users and for which database table you want
the scripts to be created. You also can tell, if this table has a
subtable or supertable. Refer to the Booosta manual if you do not know
what this is. We repeat this step for all 3 database tables we created
previously and we create the files for the admin users first:
As you see, course is a subtable of lecturer and lecturer a subtable of
course. registration does not have any sub- or supertables.
After you did this you will notice, that in your main menu there are
two new links: Lecturer and Registration. Two? Where is course? course
is a subtable and does not get a menu entry by default. As every course
belongs to a certain lecturer, so they can be accessed when editing the
lecturer. We will see this later.
Now it is time to remember to delete the file ENABLE_MKFILES from your web root.
Previous -
Next