[31506] trunk/www/includes
jmpp at macports.org
jmpp at macports.org
Sun Nov 25 23:37:06 PST 2007
Revision: 31506
http://trac.macosforge.org/projects/macports/changeset/31506
Author: jmpp at macports.org
Date: 2007-11-25 23:37:05 -0800 (Sun, 25 Nov 2007)
Log Message:
-----------
Load images (at symbol and xhtml & css tags) from an absolute path through a new $IMGDIR variable.
Modified Paths:
--------------
trunk/www/includes/common.inc
trunk/www/includes/footer.inc
Modified: trunk/www/includes/common.inc
===================================================================
--- trunk/www/includes/common.inc 2007-11-26 07:17:53 UTC (rev 31505)
+++ trunk/www/includes/common.inc 2007-11-26 07:37:05 UTC (rev 31506)
@@ -100,7 +100,9 @@
# Obfuscate e-mail addresses:
function obfuscate_email($email) {
- return "<span class='email'>" . str_replace('@', "<img src='img/at.gif' alt='at' />", $email)."</span>";
+ $IMGDIR = dirname($_SERVER['SCRIPT_NAME']) . '/img';
+
+ return "<span class='email'>" . str_replace('@', "<img src='$IMGDIR/at.gif' alt='at' />", $email) . "</span>";
}
Modified: trunk/www/includes/footer.inc
===================================================================
--- trunk/www/includes/footer.inc 2007-11-26 07:17:53 UTC (rev 31505)
+++ trunk/www/includes/footer.inc 2007-11-26 07:37:05 UTC (rev 31506)
@@ -3,13 +3,15 @@
/* $Id$ */
/* Copyright (c) 2004, OpenDarwin. */
/* Copyright (c) 2004-2007, The MacPorts Project. */
+ $IMGDIR = dirname($_SERVER['SCRIPT_NAME']) . '/img/';
?>
<div id="footer">
- <p><a href="http://validator.w3.org/check?uri=referer"><img src="img/valid-xhtml11-blue.png" alt="Valid XHTML 1.1" />
- </a> <a href="http://jigsaw.w3.org/css-validator/check/referer"><img src="img/vcss.png" alt="Valid CSS!" /></a></p>
+ <p><a href="http://validator.w3.org/check?uri=referer"><img src="<?php print $IMGDIR . 'valid-xhtml11-blue.png'; ?>"
+ alt="Valid XHTML 1.1" /></a> <a href="http://jigsaw.w3.org/css-validator/check/referer"><img src="<?php print $IMGDIR
+ . 'vcss.png'; ?>" alt="Valid CSS!" /></a></p>
<p>Copyright © 2002–<?php print date("Y"); ?>, <a href="http://www.macports.org/">The MacPorts Project</a>.
Hosted by <a href="http://www.macosforge.org">Mac OS Forge</a>. All rights reserved.</p>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.macosforge.org/pipermail/macports-changes/attachments/20071125/fa07d2cb/attachment.html
More information about the macports-changes
mailing list