forked from leftypol/leftypol
Stylesheets, etc.
This commit is contained in:
parent
99a51ddca9
commit
15a74b1523
7 changed files with 172 additions and 10 deletions
|
@ -15,7 +15,7 @@
|
|||
if(!isset($config['url_stylesheet']))
|
||||
$config['url_stylesheet'] = $config['root'] . 'style.css';
|
||||
if(!isset($config['url_javascript']))
|
||||
$config['url_javascript'] = $config['root'] . 'script.js';
|
||||
$config['url_javascript'] = $config['root'] . 'main.js';
|
||||
|
||||
if(!isset($config['post_url']))
|
||||
$config['post_url'] = $config['root'] . $config['file_post'];
|
||||
|
@ -61,6 +61,9 @@
|
|||
else
|
||||
$config['uri_img'] = sprintf($config['uri_img'], $board['dir']);
|
||||
|
||||
if(!isset($config['uri_stylesheets']))
|
||||
$config['uri_stylesheets'] = $config['root'];
|
||||
|
||||
if($config['root_file']) {
|
||||
chdir($config['root_file']);
|
||||
}
|
||||
|
@ -840,6 +843,22 @@
|
|||
}
|
||||
}
|
||||
|
||||
function buildJavascript() {
|
||||
global $config;
|
||||
|
||||
$stylesheets = Array();
|
||||
foreach($config['stylesheets'] as $name => $uri) {
|
||||
$stylesheets[] = Array(
|
||||
'name' => addslashes($name),
|
||||
'uri' => addslashes((!empty($uri) ? $config['uri_stylesheets'] : '') . $uri));
|
||||
}
|
||||
|
||||
file_put_contents($config['file_script'], Element('main.js', Array(
|
||||
'config' => $config,
|
||||
'stylesheets' => $stylesheets
|
||||
)));
|
||||
}
|
||||
|
||||
function isDNSBL() {
|
||||
$dns_black_lists = file('./dnsbl.txt', FILE_IGNORE_NEW_LINES);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue