1
0
mirror of https://github.com/vichan-devel/vichan.git synced 2024-12-21 03:45:58 +01:00
vichan/templates/themes/basic/info.php

54 lines
1.4 KiB
PHP
Raw Normal View History

2011-04-14 14:13:39 +02:00
<?php
$theme = Array();
// Theme name
$theme['name'] = 'Basic';
// Description (you can use Tinyboard markup here)
2012-02-07 23:08:13 +01:00
$theme['description'] = 'Extremely basic news listing for the homepage. Enabling boardlinks is recommended for this theme.';
$theme['version'] = 'v0.9.1';
2011-04-14 14:13:39 +02:00
// Theme configuration
$theme['config'] = Array();
$theme['config'][] = Array(
'title' => 'Site title',
2011-04-14 14:13:39 +02:00
'name' => 'title',
'type' => 'text'
);
$theme['config'][] = Array(
'title' => 'Slogan',
'name' => 'subtitle',
'type' => 'text',
'comment' => '(optional)'
);
$theme['config'][] = Array(
'title' => 'File',
'name' => 'file',
'type' => 'text',
'default' => $config['file_index'],
'comment' => '(eg. "index.html")'
);
$theme['config'][] = Array(
'title' => '# of recent entries',
'name' => 'no_recent',
'type' => 'text',
'default' => 0,
'size' => 3,
'comment' => '(number of recent news entries to display; "0" is infinite)'
2011-04-14 14:13:39 +02:00
);
// Unique function name for building everything
$theme['build_function'] = 'basic_build';
$theme['install_callback'] = 'build_install';
2012-05-05 17:33:10 +02:00
if (!function_exists('build_install')) {
function build_install($settings) {
2012-05-05 17:33:10 +02:00
if (!is_numeric($settings['no_recent']) || $settings['no_recent'] < 0)
2012-02-14 10:45:27 +01:00
return Array(false, '<strong>' . utf8tohtml($settings['no_recent']) . '</strong> is not a non-negative integer.');
}
}