1 | <?php |
||
7 | class Blog { |
||
8 | private static $force_login_comment; |
||
9 | private static $article_index; |
||
10 | private static $validate_comment; |
||
11 | private static $category; |
||
12 | |||
13 | public static $router_parameter; |
||
14 | |||
15 | private static $values = []; |
||
16 | |||
17 | //-------------------------- BUILDER ----------------------------------------------------------------------------// |
||
18 | public function __construct() { |
||
21 | //-------------------------- END BUILDER ----------------------------------------------------------------------------// |
||
22 | |||
23 | |||
24 | //-------------------------- GETTER ----------------------------------------------------------------------------// |
||
25 | /** |
||
26 | * @return array |
||
27 | * get array of all values wich will be used in the page |
||
28 | */ |
||
29 | public static function getValues() { |
||
32 | |||
33 | /** |
||
34 | * this function load the configuration of the blog |
||
35 | */ |
||
36 | private static function getConfiguration() { |
||
47 | |||
48 | /** |
||
49 | * @return mixed |
||
50 | * this function get force login comment, if return 1 the user must be connected to post a comment |
||
51 | * on the article |
||
52 | */ |
||
53 | public static function getForceLoginComment() { |
||
60 | |||
61 | /* |
||
62 | * funciton that return the max nuber of article that we will get on index page |
||
63 | */ |
||
64 | public static function getArticleIndex() { |
||
72 | |||
73 | /** |
||
74 | * @return mixed |
||
75 | * function return if a comment must be validate to be displayed on the website only if this function |
||
76 | * return 1 |
||
77 | */ |
||
78 | public static function getValidateComment() { |
||
85 | |||
86 | public static function getCategory() { |
||
93 | //-------------------------- END GETTER ----------------------------------------------------------------------------// |
||
94 | |||
95 | |||
96 | //-------------------------- SETTER ----------------------------------------------------------------------------// |
||
97 | /** |
||
98 | * @param $values |
||
99 | * can set values while keep older infos |
||
100 | */ |
||
101 | public static function setValues($values) { |
||
104 | //-------------------------- END SETTER ----------------------------------------------------------------------------// |
||
105 | } |