-
Notifications
You must be signed in to change notification settings - Fork 6
/
static.php
61 lines (47 loc) · 1.24 KB
/
static.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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
<?php
/***************************************************************************
* static.php
*
* Jul 05, 07:00:00 2009
* Copyright 2009 Istvan Petres (aka P.I.Julius)
* For licensing, see LICENSE or http://jcore.net/license
****************************************************************************/
include_once('config.inc.php');
include_once('lib/api.class.php');
date_default_timezone_set(PAGE_TIMEZONE);
sql::setTimeZone();
$request = null;
$ttl = 60*60*24*365;
if (isset($_GET['request']))
$request = $_GET['request'];
if (isset($_GET['ttl']))
$ttl = $_GET['ttl'];
header('Pragma: public');
header('Cache-Control: public, max-age='.$ttl);
header('Expires: '.gmdate('D, d M Y H:i:s', time()+$ttl).' GMT');
switch(strtolower($request)) {
case 'jquery':
include_once('lib/jquery.class.php');
jQuery::displayJS();
break;
case 'js':
include_once('lib/jquery.class.php');
jQuery::displayPluginsJS();
break;
case 'css':
include_once('lib/css.class.php');
css::displayCSS();
break;
case 'css3pie':
include_once('lib/css.class.php');
css::display3PIE();
break;
case 'ckeditor':
include_once('lib/ckeditor.class.php');
ckEditor::displayJS();
break;
default:
break;
}
?>