source: trunk/www/includes/header.inc @ 29367

Last change on this file since 29367 was 29102, checked in by jmpp@…, 13 years ago
  • New guide's URL is likely to change, so abstract it into a variable and use it;
  • Comment on the two ideas I have for combining the new ticketing guidelines on the new guide and trac's 'newticket' handler page;
  • Add the "Become a Member" new (and hopefully last) shortcut;
  • Reorder the shortcuts a bit once again... I think they look nice like this, but I've been looking at this for far too long already and therefore would appreciate a pair of fresh eyes looking at the sidebar,
  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.2 KB
Line 
1<?php
2/* $Id: header.inc 29102 2007-09-15 05:07:36Z jmpp@macports.org $ */
3$PHP_SELF = $_SERVER['PHP_SELF'];
4global $mp_version_major, $trac_url, $svn_url, $downloads, $guide_url;
5?>
6
7<h1>
8    <a href="http://www.macports.org/" title="MacPorts"><span class="accessibility">MacPorts</span></a>
9</h1>
10<p class="accessibility"><a href="#content">Skip to Content</a></p>
11<div id="header">
12    <a id="download" href="getmp.php"><span class="accessibility">Download MacPorts</span></a>
13    <span class="accessibility">View site in</span>
14    <span><a href="#" id="language"><img src="img/en-enabled.png" alt="English" width="30" height="48" /></a></span>
15    <span id="languages">
16        <a href="#"><img src="img/fr-disabled.png" alt="Fran&ccedil;ais" width="30" height="48" /></a><a href="#"><img src="img/es-disabled.png" alt="Espa&ntilde;ol" width="30" height="48" /></a><a href="#"><img src="img/ru-disabled.png" alt="" width="30" height="48" /></a><a href="#"><img src="img/it-disabled.png" alt="Italiano" width="30" height="48" /></a>
17    </span>
18</div>
19
20<div id="navigation">
21    <dl>
22        <dt>Getting Started</dt>
23        <dd>
24            <ul>
25<?php
26                $pages = array (
27                    'Home' => 'index.php',
28                    'Get MacPorts' => 'getmp.php',
29                    'Available Ports' => 'ports.php',
30                    'Documentation' => $guide_url,
31                    'Support &amp; Development' => $trac_url
32                );
33                foreach ($pages as $title => $url) {
34                    if (basename($PHP_SELF) == $url) {
35                        echo "<li class=\"selected\"><a href=\"$url\" title=\"$title\">$title</a></li>\n";
36                    } else {
37                        echo "<li><a href=\"$url\" title=\"$title\">$title</a></li>\n";
38                    }
39                }
40?>
41            </ul>
42        </dd>
43        <dt>Shortcuts</dt>
44        <dd>
45            <ul>
46<?php
47                $shortcuts = array (
48                    'Downloads' => $downloads,
49                    'MacPorts FAQ' => $trac_url . 'wiki/FAQ',
50                    // We should either link to the new ticketing guidelines below, while at the same
51                    // time including a link to trac's 'newticket' handler page on the former, or link
52                    // to them off some kind of banner on the latter.
53                    'Report a Bug' => $trac_url . 'newticket',
54                    'Blog' => 'blog/',
55                    'Subversion Repository' => $svn_url,
56                    'MacPorts Team' => $trac_url . 'wiki/MacPortsDevelopers',
57                    'Becoming a Member' => $guide_url . '#project.membership'
58                );
59                foreach ($shortcuts as $title => $url) {
60                    if (basename($PHP_SELF) == $url) {
61                        echo "<li class=\"selected\"><a href=\"$url\" title=\"$title\">$title</a></li>\n";
62                    } else {
63                        echo "<li><a href=\"$url\" title=\"$title\">$title</a></li>\n";
64                    }
65                }
66?>
67            </ul>
68        </dd>
69    </dl>
70</div>
71
72<p class="warning"> Warning: This is just a test installation of a new design for the MacPorts project page,
73official site is located at <a href="http://www.macports.org">http://www.macports.org</a> as always.</p>
Note: See TracBrowser for help on using the repository browser.