Add (again) server side rendering ! the list of user agent need to be completed but it should work.
This commit is contained in:
parent
9ff4bd2476
commit
9c8ec7fb8a
3 changed files with 46 additions and 0 deletions
5
base.php
5
base.php
|
@ -10,6 +10,11 @@ define ("VERSION", "0.6.1");
|
|||
define ("DB", "db");
|
||||
date_default_timezone_set($config['default_timezone']);
|
||||
|
||||
function useServerSideRendering () {
|
||||
global $config;
|
||||
return preg_match("/" . $config['cops_server_side_render'] . "/", $_SERVER['HTTP_USER_AGENT']);
|
||||
}
|
||||
|
||||
function getURLParam ($name, $default = NULL) {
|
||||
if (!empty ($_GET) && isset($_GET[$name]) && $_GET[$name] != "") {
|
||||
return $_GET[$name];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue