Changing the default site title

Edit yg_framework/settings.php and change the value of DEFAULT_TITLE. If you are developing, change DEBUG to True - this will allow the framework to output debugging messages when an error occurs.

Editing the default homepage

The content of the homepage comes from yg_framework/templates/home.php. Edit this page to change the content.

Adding a new page

Create a new php page in yg_framework/templates/ and fill with the <body> content of the page.

Edit yg_framework/views.php and create a new View class named after the file you have just created. There is a stub class in this file you can copy to get the format.

Edit yg_framework/urls.php and add a new route to the array. The key is the URI of the page on your domain (relative to WEB_ROOT) and the value is the name of your view.

Linking to a view

The View class contains a helper to generate links to pages using the routing array defined in urls.php. The syntax of this can be found in the API documentation and an example is provided in the default home page of the framework.

Adding and removing css and JavaScript files

The View class contains a method to change the external includes for a page. By default, static/main.css and static/main.js are included. If you wish to change this, call the add and remove functions as documented in the API documentation in the build() definition of the view in views.php.