[Pyxine-checkins] htdocs/pyxine index.tmpl,1.3,1.4
Status: Pre-Alpha
Brought to you by:
dairiki
|
From: <da...@us...> - 2003-02-10 18:55:47
|
Update of /cvsroot/pyxine/htdocs/pyxine
In directory sc8-pr-cvs1:/tmp/cvs-serv3490/pyxine
Modified Files:
index.tmpl
Log Message:
Add link to xine homepage.
Add titles (tool-tips) to the links.
Index: index.tmpl
===================================================================
RCS file: /cvsroot/pyxine/htdocs/pyxine/index.tmpl,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- index.tmpl 10 Feb 2003 17:45:10 -0000 1.3
+++ index.tmpl 10 Feb 2003 18:55:44 -0000 1.4
@@ -1,38 +1,48 @@
<hr class="hide" />
<?php
-$INDEX = array('Pages' =>
- array("Home" => "http://pyxine.sourceforge.net/"),
+function index_head($head) {
+ static $first = true;
+ if (!$first) {
+ ?><span class="hide"> </span><?php
+ }
+ $first = false;
+ ?><strong class="h2"><?=htmlspecialchars($head)?><span class="hide">:</span></strong>
+ <?php
+}
- 'Links' =>
- array("SF Project Info" =>
- "http://sourceforge.net/projects/pyxine",
-
- "Downloads" =>
- "http://sourceforge.net/project/showfiles.php?group_id=73236",
-
- "CVS Repo" =>
- "http://sourceforge.net/cvs/?group_id=73236",
+function index_entry($text, $url, $title=false) {
+ ?><a href="<?=htmlspecialchars($url)?>"<?php
+ if ($text == $GLOBAL['SELECTED']) {
+ ?> id="selected"<?php
+ }
+ if (!$title)
+ $title = $text;
+ ?> title="<?=htmlspecialchars($title)?>"><?=htmlspecialchars($text)?></a>
+ <?php
+}
- "Freshmeat listing" =>
- "http://freshmeat.net/projects/pyxine",
- )
- );
+index_head('Pages');
+index_entry('Home',
+ "http://pyxine.sourceforge.net/",
+ "The Pyxine Home Page");
-$first = true;
+index_head('SourceForge');
+index_entry("Project Info",
+ "http://sourceforge.net/projects/pyxine",
+ "SourceForge project info for Pyxine");
+index_entry("Downloads",
+ "http://sourceforge.net/project/showfiles.php?group_id=73236");
+index_entry("CVS",
+ "http://sourceforge.net/cvs/?group_id=73236",
+ "CVS Repository");
-foreach ($INDEX as $head => $list) {
- if (!$first) {
- ?><span class="hide"> </span><?php
- }
- $first = false;
- ?><strong class="h2"><?=$head?><span class="hide">:</span></strong>
- <?php
- foreach ($list as $text => $url) {
- $class = ($text == $SELECTED) ? 'selected' : 'menu';
- ?><a href="<?=$url?>" class="<?=$class?>"><?=$text?></a>
- <?php
- }
-}
+index_head('Links');
+index_entry("xine",
+ "http://xinehq.de",
+ "The xine home page");
+index_entry("freshmeat",
+ "http://freshmeat.net/projects/pyxine",
+ "The freshmeat listing for Pyxine");
?>
<hr class="hide" />
|