2 rcs_id('$Id: head.tmpl,v 1.24 2007-07-14 12:06:27 rurban Exp $');
5 <?php if (ENABLE_XHTML_XML and strstr($request->get('HTTP_ACCEPT'),'application/xhtml+xml')) { ?>
6 <meta http-equiv="Content-Type" content="application/xhtml+xml; charset=<?=$charset?>" />
8 <meta http-equiv="Content-Type" content="text/html; charset=<?=$charset?>" />
10 <meta http-equiv="Content-Style-Type" content="text/css" />
11 <meta http-equiv="Content-Language" content="<?=$GLOBALS['LANG']?>" />
12 <?php $ROBOTS_CONTENT = isset($ROBOTS_META) ? $ROBOTS_META : "noindex,nofollow"; ?>
13 <meta name="robots" content="<?= $ROBOTS_CONTENT ?>" />
14 <?php if (!empty($PAGE_DESCRIPTION)) { ?>
15 <meta name="description" content="<?=$PAGE_DESCRIPTION?>" />
17 <?php if (!empty($PAGE_KEYWORDS)) { ?>
18 <meta name="keywords" content="<?=$PAGE_KEYWORDS?>" />
20 <meta name="language" content="<?=$GLOBALS['LANG']?>" />
21 <meta name="document-type" content="Public" />
22 <meta name="document-rating" content="General" />
23 <meta name="generator" content="PhpWiki" />
24 <meta name="PHPWIKI_VERSION" content="<?=PHPWIKI_VERSION?>" />
25 <base href="<?=PHPWIKI_BASE_URL?>" />
26 <link rel="shortcut icon" href="<?=$WikiTheme->getImageURL('favicon.ico')?>" />
28 * Additional navigation links are provided here in the html header for browsers
29 * which support them: Mozilla, iCab, Amaya (and certain versions of Opera??).
31 * See http://www.w3.org/TR/html401/struct/links.html#edef-LINK
32 * http://www.euronet.nl/~tekelenb/WWW/LINK/index.html
34 <?php /* The next few lines are wrapped in an odd manner to allow gettext string extraction: cd locale;make */ ?>
35 <link rel="home" title="<?=HOME_PAGE?>" href="<?=WikiURL(HOME_PAGE)?>" />
36 <link rel="help" title="<?=
37 _("HowToUseWiki")?>" href="<?=WikiURL(
38 _("HowToUseWiki"))?>" />
39 <link rel="copyright" title="<?=COPYRIGHTPAGE_TITLE?>" href="<?=COPYRIGHTPAGE_URL?>" />
40 <link rel="author" title="<?=AUTHORPAGE_TITLE?>" href="<?=AUTHORPAGE_URL?>" />
41 <link rel="search" title="<?=
42 _("FindPage")?>" href="<?=WikiURL(
45 * Provide alternate variations of the page content:
46 * 'viewsource' and 'browse'.
47 * Translated pages could go here too.
49 if (!empty($revision)) {
50 $args = $request->getArgs();
51 $action = empty($args['action']) ? 'browse' : $args['action'];
52 if (!($action == "viewsource")) {
53 $alternatelinkTitle = fmt("%s: %s", _("View Source"), $page->getName());
54 $alternatelinkUrl = WikiURL($revision, array('action' => 'viewsource'));
56 if (!($action == "browse")) {
57 $alternatelinkTitle = $page->getName();
58 $alternatelinkUrl = WikiURL($revision, array('action' => 'browse'));
60 <link rel="alternate" title="<?= $alternatelinkTitle ?>" href="<?= $alternatelinkUrl ?>" />
63 * Link tag for RSS auto-discovery. See
64 * http://diveintomark.org/archives/2002/05/30.html#rss_autodiscovery
65 * http://www.oreillynet.com/cs/weblog/view/wlg/1475
68 <link rel="alternate" type="application/rss+xml" title="RSS" href="<?=WikiURL(
69 _("RecentChanges"), array('format' => 'rss'))?>" />
71 * Add some user-specific links.
73 <?php if (!$user->isSignedIn()) {
74 /* For users not signed in */ ?>
75 <link rel="bookmark" title="<?=
76 _("SandBox")?>" href="<?=WikiURL(
78 <link rel="bookmark" title="<?=
79 _("WikiWikiWeb")?>" href="<?=WikiURL(
80 _("WikiWikiWeb"))?>" />
83 <?php if ($user->isAdmin()) {
84 /* Only for the Administrator */ ?>
85 <link rel="bookmark" title="<?=
86 _("PhpWikiAdministration")?>" href="<?=WikiURL(
87 _("PhpWikiAdministration"))?>" />
89 <?php if ($user->isSignedIn()) {
90 /* For signed-in users */ ?>
91 <link rel="bookmark" title="<?=
92 _("UserPreferences")?>" href="<?=WikiURL(
93 _("UserPreferences"))?>" />
94 <?php /* User's calendar page
96 $UserCalPageTitle = $user->getId() . SUBPAGE_SEPARATOR ._("Calendar");
97 $UserCalPageUrl = WikiURL($UserCalPageTitle);
99 <link rel="bookmark" title="<?= $UserCalPageTitle ?>" href="<?= $UserCalPageUrl ?>" />
100 <?php /* Today's calendar page for the user if it exists
102 $UserCalPageTodayTitle = $UserCalPageTitle . SUBPAGE_SEPARATOR . strftime("%Y-%m-%d", time()); //FIXME
103 $dbi = $request->getDbh();
104 if ($dbi->isWikiPage($UserCalPageTodayTitle)) {
105 $UserCalPageTodayUrl = WikiURL($UserCalPageTodayTitle);
107 <link rel="bookmark" title="<?= $UserCalPageTodayTitle ?>" href="<?= $UserCalPageTodayUrl ?>" />
109 <?php } //end of links for signed-in user ?>
110 <?= $WikiTheme->getCSS() ?><?php
111 // avoid redundant bookmark title for custom home page
112 if ($page->getName() == WIKI_NAME && HOME_PAGE == WIKI_NAME)
115 $pagetitle = " - ". AsString($TITLE);
117 <title><?= WIKI_NAME.$pagetitle ?></title>
118 <?= $WikiTheme->getMoreHeaders() ?>
121 // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
122 // $Log: not supported by cvs2svn $
123 // Revision 1.23 2005/10/10 20:02:54 rurban
124 // add one more header
126 // Revision 1.22 2005/01/25 07:15:47 rurban
127 // fix ROBOTS_META warning, break xgettext strings, add log as comment
129 // Revision 1.4 2004/06/18 08:40:39 rurban
130 // renamed global $Theme to $WikiTheme (gforge nameclash)
132 // Revision 1.3 2004/06/04 20:34:11 rurban
133 // Put several _("") into new lines if inside attr="", so that xgettext
134 // can pick it up. (Suggested by Pierrick Meignen)
136 // Revision 1.2 2004/06/03 12:30:38 rurban
137 // support edit_toolbar in other themes
139 // Revision 1.1 2004/05/12 19:42:16 rurban
140 // new Crao theme by Arnaud Fontaine and Laurent Lunati
142 // Revision 1.13 2003/12/05 15:36:39 carstenklapp
143 // Improvements: to make it easier to run multiple wikis off of one set
144 // of code, urls for link rel author and copyright now defined in
146 // Bugfix: updated language meta tag to use DEFAULT_LANGUAGE constant
147 // instead of old LANG global.
148 // Internal change: Eliminated RECENT_CHANGES constant from RSS link,
149 // just use the easily localizable _("RecentChanges").
152 // Revision 1.12 2003/11/22 17:58:43 carstenklapp
153 // Minor internal change: Removed redundant call to gettext within
154 // fmt(). (locale make: head.tmpl:49: warning: keyword nested in keyword
157 // Revision 1.11 2003/11/21 23:06:12 carstenklapp
158 // Bugfix: Some <link rel=...> links in Mozilla/iCab were always linking
159 // to the english pages even when DEFAULT_LANGUAGE != 'en'. (Rewrapped
160 // text for a more complete xgettext string extraction: 'cd
161 // phpwiki/locale;make' to update po/mo files).
163 // Revision 1.10 2003/03/07 20:51:59 dairiki
164 // New feature: Automatic extraction of keywords (for the meta keywords tag)
165 // from Category* and Topic* links on each page.
167 // Revision 1.9 2003/03/07 02:45:51 dairiki
168 // Rename BASE_URL to PHPWIKI_BASE_URL. Lycos pre-defines BASE_URL (to
171 // Revision 1.8 2003/03/05 21:38:15 dairiki
172 // More HTML comment reduction patches by "Klaus-Guenter Leiss"
173 // <Leiss.Klaus-Guenter@epost.de>
175 // (With a few adjustments by me. Any bugs are probably my fault.)
177 // Revision 1.7 2003/02/26 22:27:17 dairiki
178 // Fix and refactor FrameInclude plugin (more or less).
180 // (This should now generate valid HTML. Woohoo!)
182 // The output when using the Sidebar theme is ugly enough that it should
183 // be considered broken. (But the Sidebar theme appears pretty broken in
184 // general right now.)
186 // (Personal comment (not to be taken personally): I must say that I
187 // remain unconvinced of the usefulness of this plugin.)
189 // Revision 1.6 2003/01/11 22:29:47 carstenklapp
190 // Tweak redundant bookmark title when browsing a custom home page with
191 // the same name as the wiki (i.e. avoid titles like "MyWiki - MyWiki"
192 // when HOME_PAGE==WIKI_NAME)