]> CyberLeo.Net >> Repos - SourceForge/phpwiki.git/blob - themes/Hawaiian/themeinfo.php
Remove $Id$
[SourceForge/phpwiki.git] / themes / Hawaiian / themeinfo.php
1 <?php
2 // Avoid direct call to this file.
3 // PHPWIKI_VERSION is defined in lib/prepend.php
4 if (!defined('PHPWIKI_VERSION')) {
5     header("Location: /");
6     exit;
7 }
8
9 /**
10  * WikiWiki Hawaiian theme for PhpWiki.
11  */
12
13 require_once 'lib/WikiTheme.php';
14
15 class WikiTheme_Hawaiian extends WikiTheme {
16     function getCSS() {
17         // FIXME: this is a hack which will not be needed once
18         //        we have dynamic CSS.
19         $css = WikiTheme::getCSS();
20         $css->pushcontent(HTML::style(array('type' => 'text/css'),
21                              new RawXml(sprintf("<!--\nbody {background-image: url(%s);}\n-->",
22                                                 $this->getImageURL('uhhbackground.jpg')))));
23         return $css;
24     }
25
26     function load() {
27    // CSS file defines fonts, colors and background images for this
28    // style.  The companion '*-heavy.css' file isn't defined, it's just
29    // expected to be in the same directory that the base style is in.
30
31    $this->setDefaultCSS('Hawaiian', 'Hawaiian.css');
32    $this->addAlternateCSS(_("Printer"), 'phpwiki-printer.css', 'print, screen');
33    $this->addAlternateCSS(_("Modern"), 'phpwiki-modern.css');
34    $this->addAlternateCSS('PhpWiki', 'phpwiki.css');
35
36    /**
37     * The logo image appears on every page and links to the HomePage.
38     */
39    $this->addImageAlias('logo', 'PalmBeach.jpg');
40    $this->addImageAlias('logo', WIKI_NAME . 'Logo.png');
41
42    /**
43     * The Signature image is shown after saving an edited page. If this
44     * is set to false then the "Thank you for editing..." screen will
45     * be omitted.
46     */
47    //$this->addImageAlias('signature', 'SubmersiblePiscesV.jpg');
48    $this->addImageAlias('signature', 'WaterFall.jpg');
49    $this->addImageAlias('signature', WIKI_NAME . "Signature.png");
50    // Uncomment this next line to disable the signature.
51    //$this->addImageAlias('signature', false);
52
53    // If you want to see more than just the waterfall let a random
54    // picture be chosen for the signature image:
55    //include_once($this->file('lib/random.php'));
56    include_once("themes/$this->_name/lib/random.php");
57    $imgSet = new randomImage($this->file("images/pictures"));
58    $imgFile = "pictures/" . $imgSet->filename;
59    $this->addImageAlias('signature', $imgFile);
60
61    //To test out the randomization just use logo instead of signature
62    //$this->addImageAlias('logo', $imgFile);
63
64    /*
65     * Link Icons
66     */
67    $this->setLinkIcon('interwiki');
68    $this->setLinkIcon('*', 'flower.png');
69
70    $this->setButtonSeparator(' ');
71
72    /**
73     * WikiWords can automatically be split by inserting spaces between
74     * the words. The default is to leave WordsSmashedTogetherLikeSo.
75     */
76    $this->setAutosplitWikiWords(true);
77
78    /*
79     * You may adjust the formats used for formatting dates and times
80     * below.  (These examples give the default formats.)
81     * Formats are given as format strings to PHP strftime() function See
82     * http://www.php.net/manual/en/function.strftime.php for details.
83     * Do not include the server's zone (%Z), times are converted to the
84     * user's time zone.
85     */
86    //$this->setDateFormat("%B %d, %Y");       // must not contain time
87
88     }
89 }
90
91 $WikiTheme = new WikiTheme_Hawaiian('Hawaiian');
92
93 // Local Variables:
94 // mode: php
95 // tab-width: 8
96 // c-basic-offset: 4
97 // c-hanging-comment-ender-p: nil
98 // indent-tabs-mode: nil
99 // End: