]> CyberLeo.Net >> Repos - SourceForge/phpwiki.git/blob - themes/default/templates/head.tmpl
Put several _("") into new lines if inside attr="", so that xgettext
[SourceForge/phpwiki.git] / themes / default / templates / head.tmpl
1 <?php  // -*-html-*-
2   rcs_id('$Id: head.tmpl,v 1.17 2004-06-04 20:34:11 rurban Exp $');
3 ?>
4 <head>
5 <meta http-equiv="Content-Type" content="text/html; charset=<?=CHARSET?>" />
6 <meta http-equiv="content-language" content="<?=$GLOBALS['LANG']?>" />
7 <?php $ROBOTS_CONTENT = $ROBOTS_META ? $ROBOTS_META : "noindex,nofollow"; ?>
8 <meta name="robots" content="<?= $ROBOTS_CONTENT ?>" />
9 <?php if (!empty($PAGE_DESCRIPTION)) { ?>
10 <meta name="description" content="<?=$PAGE_DESCRIPTION?>" />
11 <?php } ?>
12 <?php if (!empty($PAGE_KEYWORDS)) { ?>
13 <meta name="keywords" content="<?=$PAGE_KEYWORDS?>" />
14 <?php } ?>
15 <meta name="language" content="<?=$GLOBALS['LANG']?>" />
16 <meta name="document-type" content="Public" />
17 <meta name="document-rating" content="General" />
18 <meta name="generator" content="PhpWiki" />
19 <meta name="PHPWIKI_VERSION" content="<?=PHPWIKI_VERSION?>" />
20 <base href="<?=PHPWIKI_BASE_URL?>" />
21 <link rel="shortcut icon" href="<?=$Theme->getImageURL('favicon.ico')?>" />
22 <?php /**
23        * Additional navigation links are provided here in the html header for browsers
24        * which support them: Mozilla, iCab, Amaya (and certain versions of Opera??).
25        *
26        * See http://www.w3.org/TR/html401/struct/links.html#edef-LINK
27        *     http://www.euronet.nl/~tekelenb/WWW/LINK/index.html
28        */ ?>
29 <?php /* The next few lines are wrapped in an odd manner to allow gettext string extraction: cd locale;make */ ?>
30 <link rel="home" title="<?=HOME_PAGE?>" href="<?=WikiURL(HOME_PAGE)?>" />
31 <link rel="help" title="<?=_("HowToUseWiki")?>" href="<?=WikiURL(
32 _("HowToUseWiki"))?>" />
33 <link rel="copyright" title="<?=COPYRIGHTPAGE_TITLE?>" href="<?=COPYRIGHTPAGE_URL?>" />
34 <link rel="author" title="<?=AUTHORPAGE_TITLE?>" href="<?=AUTHORPAGE_URL?>" />
35 <link rel="search" title="<?=_("FindPage")?>" href="<?=WikiURL(
36 _("FindPage"))?>" />
37 <?php /**
38        * Provide alternate variations of the page content:
39        * 'viewsource' and 'browse'.
40        * Translated pages could go here too.
41        */
42       if (!empty($revision)) {
43           $args = $request->getargs();
44           $action = $args['action'];
45           if (!($action == "viewsource")) {
46             $alternatelinkTitle = fmt("%s: %s", _("View Source"), $page->getName());
47             $alternatelinkUrl = WikiURL($revision, array('action' => 'viewsource'));
48           }
49           if (!($action == "browse")) {
50             $alternatelinkTitle = $page->getName();
51             $alternatelinkUrl = WikiURL($revision, array('action' => 'browse'));
52           } ?>
53 <link rel="alternate" title="<?= $alternatelinkTitle ?>" href="<?= $alternatelinkUrl ?>" />
54 <?php }
55       /**
56        * Link tag for RSS auto-discovery.  See
57        * http://diveintomark.org/archives/2002/05/30.html#rss_autodiscovery
58        * http://www.oreillynet.com/cs/weblog/view/wlg/1475
59        */
60 ?>
61 <link rel="alternate" type="application/rss+xml" title="RSS" href="<?=WikiURL(
62 _("RecentChanges"), array('format' => 'rss'))?>" />
63
64 <?php /**
65        * Add some user-specific links.
66        */ ?>
67 <?php if (!$user->isSignedIn()) {
68       /* For users not signed in */ ?>
69 <link rel="bookmark" title="<?=_("SandBox")?>" href="<?=WikiURL(
70 _("SandBox"))?>" />
71 <link rel="bookmark" title="<?=_("WikiWikiWeb")?>" href="<?=WikiURL(
72 _("WikiWikiWeb"))?>" />
73 <?php } ?>
74
75 <?php if ($user->isadmin()) {
76       /* Only for the Administrator */ ?>
77 <link rel="bookmark" title="<?=_("PhpWikiAdministration")?>" href="<?=WikiURL(
78 _("PhpWikiAdministration"))?>" />
79 <?php } ?>
80 <?php if ($user->isSignedIn()) {
81       /* For signed-in users */ ?>
82 <link rel="bookmark" title="<?=_("UserPreferences")?>" href="<?=WikiURL(
83 _("UserPreferences"))?>" />
84 <?php /* User's calendar page
85        */
86       $UserCalPageTitle = $user->getId() . SUBPAGE_SEPARATOR ._("Calendar");
87       $UserCalPageUrl = WikiURL($UserCalPageTitle);
88       ?>
89 <link rel="bookmark" title="<?= $UserCalPageTitle ?>" href="<?= $UserCalPageUrl ?>" />
90 <?php /* Today's calendar page for the user if it exists
91        */
92       $UserCalPageTodayTitle = $UserCalPageTitle . SUBPAGE_SEPARATOR . strftime("%Y-%m-%d", time()); //FIXME
93       $dbi = $request->getDbh();
94       if ($dbi->isWikiPage($UserCalPageTodayTitle)) {
95           $UserCalPageTodayUrl = WikiURL($UserCalPageTodayTitle);
96           ?>
97 <link rel="bookmark" title="<?= $UserCalPageTodayTitle ?>" href="<?= $UserCalPageTodayUrl ?>" />
98 <?php } ?>
99 <?php } //end of links for signed-in user ?>
100 <?= $Theme->getCSS() ?><?php
101   // avoid redundant bookmark title for custom home page
102   if ($page->getName() == WIKI_NAME && HOME_PAGE == WIKI_NAME)
103       $pagetitle = "";
104   else
105       $pagetitle = " - ". AsString($TITLE);
106 ?>
107 <title><?= WIKI_NAME.$pagetitle ?></title>
108 <?= $Theme->getMoreHeaders() ?>
109 </head>
110 <?php
111 // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -                         
112 // $Log: not supported by cvs2svn $
113 // Revision 1.16  2004/06/03 16:56:22  rurban
114 // added Sidebar existing calendar dates
115 //
116 // Revision 1.15  2004/05/16 23:10:45  rurban
117 // update_locale wrongly resetted LANG, which broke japanese.
118 // japanese now correctly uses EUC_JP, not utf-8.
119 // more charset and lang headers to help the browser.
120 //
121 // Revision 1.14  2004/02/17 12:19:49  rurban
122 // support to add more javascript dynamically
123 //
124 // Revision 1.13  2003/12/05 15:36:39  carstenklapp
125 // Improvements: to make it easier to run multiple wikis off of one set
126 // of code, urls for link rel author and copyright now defined in
127 // index.php.
128 // Bugfix: updated language meta tag to use DEFAULT_LANGUAGE constant
129 // instead of old LANG global.
130 // Internal change: Eliminated RECENT_CHANGES constant from RSS link,
131 // just use the easily localizable _("RecentChanges").
132 // Typo fixed.
133 //
134 // Revision 1.12  2003/11/22 17:58:43  carstenklapp
135 // Minor internal change: Removed redundant call to gettext within
136 // fmt(). (locale make: head.tmpl:49: warning: keyword nested in keyword
137 // arg)
138 //
139 // Revision 1.11  2003/11/21 23:06:12  carstenklapp
140 // Bugfix: Some <link rel=...> links in Mozilla/iCab were always linking
141 // to the english pages even when DEFAULT_LANGUAGE != 'en'. (Rewrapped
142 // text for a more complete xgettext string extraction: 'cd
143 // phpwiki/locale;make' to update po/mo files).
144 //
145 // Revision 1.10  2003/03/07 20:51:59  dairiki
146 // New feature: Automatic extraction of keywords (for the meta keywords tag)
147 // from Category* and Topic* links on each page.
148 //
149 // Revision 1.9  2003/03/07 02:45:51  dairiki
150 // Rename BASE_URL to PHPWIKI_BASE_URL.  Lycos pre-defines BASE_URL (to
151 // the wrong thing).
152 //
153 // Revision 1.8  2003/03/05 21:38:15  dairiki
154 // More HTML comment reduction patches by "Klaus-Guenter Leiss"
155 // <Leiss.Klaus-Guenter@epost.de>
156 //
157 // (With a few adjustments by me.  Any bugs are probably my fault.)
158 //
159 // Revision 1.7  2003/02/26 22:27:17  dairiki
160 // Fix and refactor FrameInclude plugin (more or less).
161 //
162 // (This should now generate valid HTML.  Woohoo!)
163 //
164 // The output when using the Sidebar theme is ugly enough that it should
165 // be considered broken.  (But the Sidebar theme appears pretty broken in
166 // general right now.)
167 //
168 // (Personal comment (not to be taken personally): I must say that I
169 // remain unconvinced of the usefulness of this plugin.)
170 //
171 // Revision 1.6  2003/01/11 22:29:47  carstenklapp
172 // Tweak redundant bookmark title when browsing a custom home page with
173 // the same name as the wiki (i.e. avoid titles like "MyWiki - MyWiki"
174 // when HOME_PAGE==WIKI_NAME)
175 //
176 ?>