/
index.php
33 lines (25 loc) · 935 Bytes
/
index.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
<?php
// Copyright 2011 RAS: Runar Ingebrigtsen, Alexander Wold og Stig Jakobsen
// Starting session
session_start();
// Include the Router class for URL routing
include 'Router.class.php'; // Only requirement to kick out other browsers
Router::chrome_or_die(); // We only accept Google Chrome for this blog
// Prepare our various Tools
include 'Tools.class.php';
// Include Model definitions
include 'Model.class.php';
include 'Comment.class.php';
include 'Post.class.php';
include 'User.class.php';
include 'Search.class.php';
// Include View definitions
include 'libs/Smarty.class.php';
include 'View.class.php';
// Include and load Controller and Tools
include 'Controller.class.php';
new Tools; // Prepare Tools
$controller = new Controller; // Load Controller
// Let the Router do its job.
Router::mapAndRun();
?>