The version of vichan running on lainchan.org
Ви не можете вибрати більше 25 тем Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.

56 рядки
1.5KB

  1. <?php
  2. $theme = array();
  3. // Theme name
  4. $theme['name'] = 'Overboard (Ukko) 4';
  5. // Description (you can use Tinyboard markup here)
  6. $theme['description'] = 'Board with threads and messages from all boards';
  7. $theme['version'] = 'v0.2';
  8. // Theme configuration
  9. $theme['config'] = array();
  10. $theme['config'][] = array(
  11. 'title' => 'Board name',
  12. 'name' => 'title',
  13. 'type' => 'text',
  14. 'default' => 'Ukko'
  15. );
  16. $theme['config'][] = array(
  17. 'title' => 'Board URI',
  18. 'name' => 'uri',
  19. 'type' => 'text',
  20. 'default' => '*',
  21. 'comment' => '(ukko for example)'
  22. );
  23. $theme['config'][] = array(
  24. 'title' => 'Subtitle',
  25. 'name' => 'subtitle',
  26. 'type' => 'text',
  27. 'comment' => '(%s = thread limit. for example "%s freshly bumped threads")'
  28. );
  29. $theme['config'][] = array(
  30. 'title' => 'Excluded boards',
  31. 'name' => 'exclude',
  32. 'type' => 'text',
  33. 'comment' => '(space seperated)'
  34. );
  35. $theme['config'][] = array(
  36. 'title' => 'Number of threads',
  37. 'name' => 'thread_limit',
  38. 'type' => 'text',
  39. 'default' => '15',
  40. );
  41. // Unique function name for building everything
  42. $theme['build_function'] = 'ukko4_build';
  43. $theme['install_callback'] = 'ukko4_install';
  44. if(!function_exists('ukko4_install')) {
  45. function ukko4_install($settings) {
  46. if (!file_exists($settings['uri']))
  47. @mkdir($settings['uri'], 0777) or error("Couldn't create " . $settings['uri'] . ". Check permissions.", true);
  48. file_write($settings['uri'] . '/ukko.js', Element('themes/ukko/ukko.js', array()));
  49. }
  50. }