mirror of
https://git.code.sf.net/p/quake/website
synced 2025-03-13 21:21:59 +00:00
News stuff -- beginning to secure the MySQL configs in a sane way, committing my news search stuff, etc.
This commit is contained in:
parent
54dcc60061
commit
540834c9df
14 changed files with 310 additions and 306 deletions
65
index.php
65
index.php
|
@ -1,33 +1,32 @@
|
|||
<? // Preamble
|
||||
$pageName = "News";
|
||||
$focused = "home"; // Dock icon name to get a border
|
||||
require("parts/preamble.php"); // Load most of document
|
||||
?>
|
||||
<!--SEARCHME-->
|
||||
<TABLE width="100%" cellSpacing="0" cellPadding="0" border="0">
|
||||
<TR vAlign="top">
|
||||
<TD colSpan="2"><? // News display
|
||||
tableBoxHeader( 'black', tableHeadColor );
|
||||
tableTitle( 'Latest News', 1, tableHeadColor );
|
||||
require("lib/sql.php");
|
||||
require("news_funcs.php");
|
||||
latestNews('1 month');
|
||||
tableBoxFooter();
|
||||
?></TD>
|
||||
</TR>
|
||||
<TR vAlign=top>
|
||||
<? tableSpacer(9, 9, 1, "black"); ?>
|
||||
</TR>
|
||||
<TR vAlign=top>
|
||||
<TD align="center">
|
||||
<? include("sponsor_incl.html"); ?>
|
||||
</TD>
|
||||
</TR>
|
||||
<TR vAlign=top>
|
||||
<? tableSpacer(9, 9, 1, "black"); ?>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<!--NOSEARCH-->
|
||||
<?
|
||||
require("parts/postamble.php"); // Finish this sucker up
|
||||
?>
|
||||
<? // Preamble
|
||||
$pageName = "News";
|
||||
$focused = "home"; // Dock icon name to get a border
|
||||
require "parts/preamble.php"; // Load most of document
|
||||
?>
|
||||
<!--SEARCHME-->
|
||||
<TABLE width="100%" cellSpacing="0" cellPadding="0" border="0">
|
||||
<TR vAlign="top">
|
||||
<TD colSpan="2"><? // News display
|
||||
tableBoxHeader (featureBgColor, featureHeadColor);
|
||||
tableTitle ('Latest News', 1, featureHeadColor);
|
||||
require "news_funcs.php";
|
||||
latestNews ('1 month');
|
||||
tableBoxFooter ();
|
||||
?></TD>
|
||||
</TR>
|
||||
<TR vAlign=top>
|
||||
<? tableSpacer (9, 9, 1, "black"); ?>
|
||||
</TR>
|
||||
<TR vAlign=top>
|
||||
<TD align="center">
|
||||
<? include "sponsor_incl.html"; ?>
|
||||
</TD>
|
||||
</TR>
|
||||
<TR vAlign=top>
|
||||
<? tableSpacer (9, 9, 1, "black"); ?>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<!--NOSEARCH-->
|
||||
<?
|
||||
require "parts/postamble.php"; // Finish this sucker up
|
||||
?>
|
||||
|
|
40
lib/auth.php
40
lib/auth.php
|
@ -27,7 +27,7 @@
|
|||
*/
|
||||
|
||||
have ('auth');
|
||||
need ('sql table');
|
||||
need ('table');
|
||||
|
||||
/* SQL definition for member list table
|
||||
CREATE TABLE members (
|
||||
|
@ -55,18 +55,18 @@ CREATE TABLE members (
|
|||
|
||||
Display a login form.
|
||||
*/
|
||||
function authLoginForm( $title )
|
||||
function authLoginForm ($title)
|
||||
{
|
||||
global $siteName, $pageName, $focused;
|
||||
|
||||
require(siteHome ."/parts/head.php"); // Load the HEAD and open BODY
|
||||
require(siteHome ."/parts/topstrip.php"); // Display top strip
|
||||
require(siteHome ."/parts/titletable.php"); // Display main title w/ logos
|
||||
require siteHome ."/parts/head.php"; // Load the HEAD and open BODY
|
||||
require siteHome ."/parts/topstrip.php"; // Display top strip
|
||||
require siteHome ."/parts/titletable.php"; // Display main title w/ logos
|
||||
?>
|
||||
<TABLE width="100%" cellSpacing="0" cellPadding="0" border="0">
|
||||
<TR vAlign="top">
|
||||
<TD bgColor="<? echo menuBgColor; ?>">
|
||||
<? include(siteHome ."/parts/menu.php"); /* menus */ ?>
|
||||
<? include siteHome . "/parts/menu.php"; ?>
|
||||
</TD>
|
||||
<TD width="100%">
|
||||
<? tableHeader("100%", "black"); ?>
|
||||
|
@ -76,7 +76,7 @@ CREATE TABLE members (
|
|||
<TR>
|
||||
<? tableSpacer( 9, 9, 1, "black"); ?>
|
||||
<TD>
|
||||
<? require(siteHome ."/parts/topmain.php"); ?>
|
||||
<? require siteHome . "/parts/topmain.php"; ?>
|
||||
</TD>
|
||||
<? tableSpacer( 9, 9, 1, "black"); ?>
|
||||
</TR>
|
||||
|
@ -117,10 +117,10 @@ CREATE TABLE members (
|
|||
</TD>
|
||||
</TR>
|
||||
<?
|
||||
tableFooter();
|
||||
tableBoxFooter();
|
||||
require (siteHome ."/parts/postamble.php");
|
||||
die();
|
||||
tableFooter ();
|
||||
tableBoxFooter ();
|
||||
require siteHome ."/parts/postamble.php";
|
||||
die ();
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -128,11 +128,11 @@ CREATE TABLE members (
|
|||
|
||||
Generate a secret key for user's session
|
||||
*/
|
||||
function authCreateSecret( $userName, $encryptedPassWord )
|
||||
function authCreateSecret ($userName, $encryptedPassWord)
|
||||
{
|
||||
$digest = md5( time() );
|
||||
$digest = md5 (time ());
|
||||
$cookie = "$userName-$encryptedPassWord-$digest";
|
||||
SetCookie( "loginInfo", $cookie, ( time() + EXPIRY ));
|
||||
SetCookie ("loginInfo", $cookie, (time() + EXPIRY));
|
||||
$query = "UPDATE members SET u_secret='$digest'" .
|
||||
" WHERE u_username='$userName'";
|
||||
|
||||
|
@ -151,8 +151,8 @@ CREATE TABLE members (
|
|||
" AND u_password=ENCRYPT('$password','$userName')";
|
||||
$result = @mysql_fetch_array (@mysql_db_query (sqlDB, $query));
|
||||
|
||||
if ( $result[auth] ) {
|
||||
authCreateSecret( $userName, $result[u_password] );
|
||||
if ($result[auth]) {
|
||||
authCreateSecret ($userName, $result[u_password]);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -161,7 +161,7 @@ CREATE TABLE members (
|
|||
|
||||
Authenticate user against SQL database using a cookie
|
||||
*/
|
||||
function authCookie( $cookie, $userName, $password )
|
||||
function authCookie ($cookie, $userName, $password)
|
||||
{
|
||||
$cookie_var = split("-", $cookie);
|
||||
$cUserName = $cookie_var[0];
|
||||
|
@ -174,10 +174,10 @@ CREATE TABLE members (
|
|||
" AND u_secret='$secret'";
|
||||
$result = @mysql_fetch_array (@mysql_db_query (sqlDB, $query));
|
||||
|
||||
if ( !($result[auth]) ) {
|
||||
authProcess ($username, $password);
|
||||
} else {
|
||||
if ($result[auth]) {
|
||||
return $cUserName;
|
||||
} else {
|
||||
authProcess ($userName, $password);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -27,10 +27,4 @@
|
|||
*/
|
||||
|
||||
have ('sql');
|
||||
|
||||
define ('sqlDB', 'quakeforge'); // Database name to use
|
||||
define ('sqlHost', 'moby'); // Hostname for database access
|
||||
define ('sqlUser', 'quakeforge'); // Username
|
||||
define ('sqlPass', '6ef/HNvv'); // Password
|
||||
|
||||
?>
|
||||
|
|
|
@ -1,67 +1,67 @@
|
|||
<? // Preamble
|
||||
$pageName = "Developer Central";
|
||||
$focused = "home"; // Dock icon name to gets a border
|
||||
$need = 'auth';
|
||||
require("../parts/preamble.php"); // Load most of document
|
||||
?>
|
||||
|
||||
<?
|
||||
function infoItem($url, $desc, $longdesc)
|
||||
{
|
||||
echo '<DL>' .
|
||||
' <DT><A href="' . $url . '"><STRONG>' . $desc . '</STRONG></A></DT>' .
|
||||
' <DD><EM>' . $longdesc . '</EM></DD>' .
|
||||
'</DL>';
|
||||
}
|
||||
?>
|
||||
<H2>Welcome to Developer Central!</H2>
|
||||
|
||||
<P>This is the area for developers to post news, edit your user information,
|
||||
and so on. Members with Admin-level access can modify news items and post
|
||||
State of the Code items here as well.
|
||||
|
||||
<P>
|
||||
<?
|
||||
tableHeader("100%", "black");
|
||||
?>
|
||||
<TR vAlign="top">
|
||||
<TD align="left">
|
||||
<?
|
||||
tableBoxHeader("100%", "black", tableHeadColor);
|
||||
tableTitle("QuakeForge Developer Resources", 1, "black");
|
||||
?>
|
||||
<TR vAlign="top">
|
||||
<TD>
|
||||
<?
|
||||
infoItem('addnews.php', 'Post News', 'Post new news items from here.');
|
||||
infoItem('userinfo.php', 'User Info', 'Display or change your user information; Please use this when your email address, phone number, or snailmail address changes.');
|
||||
infoItem('plan.php', 'Edit "plan"', 'Update this to notify the outside world what you\'re currently working on.');
|
||||
?>
|
||||
|
||||
</TD>
|
||||
</TR>
|
||||
<? tableBoxFooter() ?>
|
||||
</TD>
|
||||
<? if ($userInfo[u_admin] == 'Y') { ?>
|
||||
<TD align="right">
|
||||
<?
|
||||
tableBoxHeader(featureBgColor, tableHeadColor);
|
||||
tableTitle("Administration", 1, tableHeadColor);
|
||||
?>
|
||||
<TR>
|
||||
<TD class="featureBox" align="right">
|
||||
News [ <A href="addnews.php">Add</A> | <A href="editnews.php">Edit</A> | <A href="delnews.php">Delete</A> ]<BR>
|
||||
SotC [ <A href="addsotc.php">Add</A> | <A href="editsotc.php">Edit</A> | <A href="delsotc.php">Delete</A> ]<BR>
|
||||
User [ <A href="adduser.php">Add</A> | <A href="edituser.php">Edit</A> | <A href="deluser.php">Delete</A> ]<BR>
|
||||
</TD>
|
||||
</TR>
|
||||
<?
|
||||
tableBoxFooter();
|
||||
?>
|
||||
</TD>
|
||||
<? } ?>
|
||||
</TR>
|
||||
<? tableFooter(); ?>
|
||||
<?
|
||||
require (siteHome ."/parts/postamble.php"); // Finish this sucker up
|
||||
?>
|
||||
<? // Preamble
|
||||
$pageName = "Developer Central";
|
||||
$focused = "home"; // Dock icon name to get a border
|
||||
$need = 'auth';
|
||||
require "../parts/preamble.php"; // Load most of document
|
||||
?>
|
||||
|
||||
<?
|
||||
function infoItem($url, $desc, $longdesc)
|
||||
{
|
||||
echo '<DL>' .
|
||||
' <DT><A href="' . $url . '"><STRONG>' . $desc . '</STRONG></A></DT>' .
|
||||
' <DD><EM>' . $longdesc . '</EM></DD>' .
|
||||
'</DL>';
|
||||
}
|
||||
?>
|
||||
<H2>Welcome to Developer Central!</H2>
|
||||
|
||||
<P>This is the area for developers to post news, edit your user information,
|
||||
and so on. Members with Admin-level access can modify news items and post
|
||||
State of the Code items here as well.
|
||||
|
||||
<P>
|
||||
<?
|
||||
tableHeader("100%", "black");
|
||||
?>
|
||||
<TR vAlign="top">
|
||||
<TD align="left">
|
||||
<?
|
||||
tableBoxHeader("100%", "black", tableHeadColor);
|
||||
tableTitle("QuakeForge Developer Resources", 1, "black");
|
||||
?>
|
||||
<TR vAlign="top">
|
||||
<TD>
|
||||
<?
|
||||
infoItem('addnews.php', 'Post News', 'Post new news items from here.');
|
||||
infoItem('userinfo.php', 'User Info', 'Display or change your user information; Please use this when your email address, phone number, or snailmail address changes.');
|
||||
infoItem('plan.php', 'Edit "plan"', 'Update this to notify the outside world what you\'re currently working on.');
|
||||
?>
|
||||
|
||||
</TD>
|
||||
</TR>
|
||||
<? tableBoxFooter() ?>
|
||||
</TD>
|
||||
<? if ($userInfo[u_admin] == 'Y') { ?>
|
||||
<TD align="right">
|
||||
<?
|
||||
tableBoxHeader(featureBgColor, featureHeadColor);
|
||||
tableTitle("Administration", 1, featureHeadColor);
|
||||
?>
|
||||
<TR>
|
||||
<TD class="featureBox" align="right">
|
||||
News [ <A href="addnews.php">Add</A> | <A href="editnews.php">Edit</A> | <A href="delnews.php">Delete</A> ]<BR>
|
||||
SotC [ <A href="addsotc.php">Add</A> | <A href="editsotc.php">Edit</A> | <A href="delsotc.php">Delete</A> ]<BR>
|
||||
User [ <A href="adduser.php">Add</A> | <A href="edituser.php">Edit</A> | <A href="deluser.php">Delete</A> ]<BR>
|
||||
</TD>
|
||||
</TR>
|
||||
<?
|
||||
tableBoxFooter();
|
||||
?>
|
||||
</TD>
|
||||
<? } ?>
|
||||
</TR>
|
||||
<? tableFooter(); ?>
|
||||
<?
|
||||
require (siteHome ."/parts/postamble.php"); // Finish this sucker up
|
||||
?>
|
||||
|
|
|
@ -1,10 +1,15 @@
|
|||
<?
|
||||
function newsItem( $date, $user, $text )
|
||||
function newsItem ($date, $user, $text)
|
||||
{
|
||||
if ($user == "Theoddone33") $user = "theoddone33";
|
||||
echo '<TR><TD><DL><DT><FONT SIZE=-1>Posted on ' . $date . ' by ' . $user . '</FONT></DT>' .
|
||||
' <DD><P>' . $text . '</DD>' .
|
||||
'</DL></TD></TR>';
|
||||
echo '<TR>' .
|
||||
' <TD>' .
|
||||
' <DL>' .
|
||||
" <DT><FONT SIZE=\"-1\">Posted on $date by $user</FONT></DT>" .
|
||||
" <DD><P>$text</DD>" .
|
||||
' </DL>' .
|
||||
' </TD>' .
|
||||
'</TR>';
|
||||
}
|
||||
|
||||
function monthForm ()
|
||||
|
@ -96,9 +101,9 @@
|
|||
}
|
||||
}
|
||||
|
||||
function latestNews ( $length )
|
||||
function latestNews ($length)
|
||||
{
|
||||
need('date sql');
|
||||
need('date');
|
||||
|
||||
$conn = @mysql_pconnect (sqlHost, sqlUser, sqlPass);
|
||||
if ($conn) {
|
||||
|
@ -125,9 +130,9 @@
|
|||
}
|
||||
}
|
||||
|
||||
function monthlyNews ( $month, $year )
|
||||
function monthlyNews ($month, $year)
|
||||
{
|
||||
need('date sql');
|
||||
need('date');
|
||||
|
||||
// Do sanity checking on dates
|
||||
if (((!is_int($year)) || $year < 2000)) {
|
||||
|
@ -167,7 +172,7 @@
|
|||
|
||||
function searchNews ( $string )
|
||||
{
|
||||
need ('date sql');
|
||||
need ('date');
|
||||
|
||||
$search = AddSlashes ("%$string%");
|
||||
$conn = @mysql_pconnect (sqlHost, sqlUser, sqlPass);
|
||||
|
|
59
old_news.php
59
old_news.php
|
@ -1,30 +1,29 @@
|
|||
<?
|
||||
$pageName = 'News Archives';
|
||||
$focused = "home"; // Dock icon name to get a border
|
||||
require("parts/preamble.php"); // Load most of document
|
||||
?>
|
||||
<!--NOSEARCH-->
|
||||
<TABLE width="100%" cellSpacing="0" cellPadding="0" border="0">
|
||||
<TR vAlign="top">
|
||||
<TD colSpan="2"><?
|
||||
require ("lib/sql.php");
|
||||
require ("news_funcs.php");
|
||||
if ($month || $year) {
|
||||
tableBoxHeader( 'black', tableHeadColor );
|
||||
tableTitle( $pageName, 1, tableHeadColor );
|
||||
monthlyNews ($month, $year);
|
||||
tableBoxFooter ();
|
||||
} else {
|
||||
if ($string) {
|
||||
searchNews ($string);
|
||||
} else {
|
||||
newsItem ('now', 'Web Server', "You didn't specify a search, giving up.");
|
||||
}
|
||||
}
|
||||
?></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<!--NOSEARCH-->
|
||||
<?
|
||||
require("parts/postamble.php"); // Finish this sucker up
|
||||
?>
|
||||
<?
|
||||
$pageName = 'News Archives';
|
||||
$focused = "home"; // Dock icon name to get a border
|
||||
require "parts/preamble.php"; // Load most of document
|
||||
?>
|
||||
<!--NOSEARCH-->
|
||||
<TABLE width="100%" cellSpacing="0" cellPadding="0" border="0">
|
||||
<TR vAlign="top">
|
||||
<TD align="center"><?
|
||||
require "news_funcs.php";
|
||||
tableBoxHeader (featureBgColor, featureHeadColor);
|
||||
tableTitle ($pageName, 1, featureHeadColor);
|
||||
if ($month || $year) {
|
||||
monthlyNews ($month, $year);
|
||||
} else {
|
||||
if ($string) {
|
||||
searchNews ($string);
|
||||
} else {
|
||||
newsItem ('now', 'Web Server', "You didn't specify a search, giving up.");
|
||||
}
|
||||
}
|
||||
tableBoxFooter ();
|
||||
?></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<!--NOSEARCH-->
|
||||
<?
|
||||
require "parts/postamble.php"; // Finish this sucker up
|
||||
?>
|
||||
|
|
|
@ -2,6 +2,6 @@
|
|||
<HTML>
|
||||
<HEAD>
|
||||
<LINK REL="StyleSheet" HREF="/styles/quakeforge.css" TYPE="text/css">
|
||||
<TITLE><? echo $siteName . ': ' . $pageName; ?></TITLE>
|
||||
<TITLE><? echo "$siteName: $pageName"; ?></TITLE>
|
||||
</HEAD>
|
||||
<BODY link="#AAAAFF" aLink="#ffffff" vLink="#AAAAFF" text="white" bgColor="black" topMargin="0" bottomMargin="0" leftMargin="0" rightMargin="0" marginHeight="0" marginWidth="0">
|
||||
<BODY link="#aaaaff" aLink="#ffffff" vLink="#aaaaff" text="white" bgColor="black" topMargin="0" bottomMargin="0" leftMargin="0" rightMargin="0" marginHeight="0" marginWidth="0">
|
||||
|
|
|
@ -1,20 +1,26 @@
|
|||
<?
|
||||
// helpful constants
|
||||
if ( !defined( '_COLORS_' )) {
|
||||
if (!defined( '_COLORS_' )) {
|
||||
define('_COLORS_', 1);
|
||||
define('tableHeadColor', '#737b9c');
|
||||
define('tableBgColor', 'black');
|
||||
define('menuHeadColor', '#737b9c');
|
||||
define('menuBgColor', '#4b4f66');
|
||||
define('featureHeadColor', tableHeadColor);
|
||||
define('featureBgColor', '#252733');
|
||||
}
|
||||
|
||||
if (!defined ('_ARRAY_')) { // Treat array handler special
|
||||
require( siteHome . "/lib/array.php" );
|
||||
if (!defined ('_SQLCONSTS_')) {
|
||||
define ('_SQLCONSTS_', 1);
|
||||
require siteHome . '/../etc/sql.conf';
|
||||
}
|
||||
|
||||
if ( !defined( '_LIBFUNCS_' )) {
|
||||
|
||||
define( '_LIBFUNCS_', 1 );
|
||||
if (!defined ('_ARRAY_')) { // Treat array handler special
|
||||
require siteHome . "/lib/array.php";
|
||||
}
|
||||
|
||||
if (!defined ('_LIBFUNCS_')) {
|
||||
define ('_LIBFUNCS_', 1);
|
||||
|
||||
/*
|
||||
reqIfNeeded
|
||||
|
@ -30,7 +36,7 @@
|
|||
for ($i = 0 ; $i < count ($libs) ; $i++ ) {
|
||||
$lib = $libs[$i];
|
||||
if ((inArray ($libs[$i], $needs)) && (!inArray ($libs[$i], $has))) {
|
||||
include (siteHome . '/lib/' . $libs[$i] . '.php');
|
||||
include siteHome . "/lib/$libs[$i].php";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
198
parts/menu.php
198
parts/menu.php
|
@ -1,99 +1,99 @@
|
|||
<!-- menus -->
|
||||
<?
|
||||
function menuItemLink( $url, $desc )
|
||||
{
|
||||
echo '<A CLASS="menus" HREF="' . $url . '">' . $desc . '</A><BR>';
|
||||
}
|
||||
|
||||
function menuSectionHeader( $name, $fgColor , $bgColor, $intBgColor )
|
||||
{
|
||||
echo "\n<!-- menuSectionHeader(" . $name . ') -->' .
|
||||
'<TABLE cellSpacing="0" cellPadding="3" width="100%" border=0 bgColor="' . $bgColor . '">' .
|
||||
' <TR bgColor="' . $bgColor . '">' .
|
||||
' <TD align="center">' .
|
||||
' <IMG src="/img/blank.gif" height="1" width="135" alt="" border="0"><BR>' .
|
||||
' <SPAN class="titlebar">' . $name . '</SPAN>' .
|
||||
' </TD>' .
|
||||
' </TR>' .
|
||||
' <TR align="right" bgColor="' . $intBgColor . '">' .
|
||||
' <TD>';
|
||||
}
|
||||
|
||||
function menuSectionFooter()
|
||||
{
|
||||
echo ' </TD>' .
|
||||
' </TR>' .
|
||||
'</TABLE>';
|
||||
}
|
||||
|
||||
function qfMenu()
|
||||
{
|
||||
menuSectionHeader( "Project", 'white', menuHeadColor, menuBgColor );
|
||||
menuItemLink( "/", "Latest News" );
|
||||
menuItemLink( "/news.php", "Old News" );
|
||||
menuItemLink( "/files.php", "Downloads" );
|
||||
menuItemLink( "http://sourceforge.net/bugs/?group_id=882", "Bug Reports" );
|
||||
menuItemLink( "http://sourceforge.net/mail/?group_id=882", "Mailing Lists" );
|
||||
menuItemLink( "/board/", "Web Forum" );
|
||||
menuSectionFooter();
|
||||
}
|
||||
|
||||
function develMenu()
|
||||
{
|
||||
menuSectionHeader( "Developers", 'white', menuHeadColor, menuBgColor );
|
||||
menuItemLink( "http://sourceforge.net/cvs/?group_id=882", "CVS Access" );
|
||||
menuItemLink( "/devtools.php", "Developer Tools" );
|
||||
menuItemLink( "/plans.php", "Developer Plans" );
|
||||
menuItemLink( "/progress.php", "Progress" );
|
||||
menuItemLink( "/sotc/", "State of the Code" );
|
||||
menuItemLink( "/research/", "Research Center" );
|
||||
menuItemLink( "http://sourceforge.net/patch/?group_id=882", "Patch Manager" );
|
||||
// menuItemLink( "http://sourceforge.net/support/?group_id=882", "Support Manager" );
|
||||
menuItemLink( "http://sourceforge.net/pm/?group_id=882", "Task Manager" );
|
||||
menuSectionFooter();
|
||||
}
|
||||
|
||||
function sfMenu()
|
||||
{
|
||||
menuSectionHeader( "SourceForge", 'white', menuHeadColor, menuBgColor );
|
||||
menuItemLink( "http://sourceforge.net/", "Homepage" );
|
||||
menuItemLink( "http://sourceforge.net/snippet/", "Code Snippet Library" );
|
||||
menuItemLink( "http://sourceforge.net/softwaremap/", "Software Map" );
|
||||
menuItemLink( "http://sourceforge.net/new/", "New Releases" );
|
||||
menuItemLink( "http://sourceforge.net/docs/site/", "Site Documentation" );
|
||||
menuItemLink( "http://sourceforge.net/top/", "Top Projects" );
|
||||
menuItemLink( "http://sourceforge.net/mirrors/", "Other Site Mirrors" );
|
||||
menuSectionFooter();
|
||||
}
|
||||
|
||||
function searchMenu()
|
||||
{
|
||||
menuSectionHeader( "Search", 'white', menuHeadColor, menuBgColor );
|
||||
echo '<CENTER><FONT size="-2">' .
|
||||
'<FORM action="search.php" method="POST">' .
|
||||
' <SELECT name="type_of_search">' .
|
||||
' <OPTION value="news">News</OPTION>' .
|
||||
' <OPTION value="site">Site</OPTION>' .
|
||||
' <OPTION value="bugs">Bug Tracking</OPTION>' .
|
||||
' <OPTION value="lists">Mailing Lists</OPTION>' .
|
||||
' <OPTION value="patches">Patches</OPTION>' .
|
||||
' </SELECT>' .
|
||||
' <BR>' .
|
||||
' <INPUT TYPE="CHECKBOX" NAME="exact" VALUE="1" CHECKED> Require Exact Match' .
|
||||
' <BR>' .
|
||||
' <INPUT TYPE="HIDDEN" NAME="forum_id" VALUE="">' .
|
||||
' <INPUT TYPE="HIDDEN" NAME="is_bug_page" VALUE="">' .
|
||||
' <INPUT TYPE="HIDDEN" NAME="group_id" VALUE="882">' .
|
||||
' <INPUT TYPE="text" NAME="words" SIZE="15" VALUE="">' .
|
||||
' <BR>' .
|
||||
' <INPUT TYPE="submit" NAME="Search" VALUE="Search">' .
|
||||
'</FORM></FONT>' .
|
||||
'</CENTER>';
|
||||
menuSectionFooter();
|
||||
}
|
||||
|
||||
qfMenu();
|
||||
develMenu();
|
||||
// sfMenu();
|
||||
searchMenu();
|
||||
?>
|
||||
<!-- menus -->
|
||||
<?
|
||||
function menuItemLink ($url, $desc)
|
||||
{
|
||||
echo '<A CLASS="menus" HREF="' . $url . '">' . $desc . '</A><BR>';
|
||||
}
|
||||
|
||||
function menuSectionHeader ($name, $fgColor , $bgColor, $intBgColor)
|
||||
{
|
||||
echo "\n<!-- menuSectionHeader(" . $name . ') -->' .
|
||||
'<TABLE cellSpacing="0" cellPadding="3" width="100%" border=0 bgColor="' . $bgColor . '">' .
|
||||
' <TR bgColor="' . $bgColor . '">' .
|
||||
' <TD align="center">' .
|
||||
' <IMG src="/img/blank.gif" height="1" width="135" alt="" border="0"><BR>' .
|
||||
' <SPAN class="titlebar">' . $name . '</SPAN>' .
|
||||
' </TD>' .
|
||||
' </TR>' .
|
||||
' <TR align="right" bgColor="' . $intBgColor . '">' .
|
||||
' <TD>';
|
||||
}
|
||||
|
||||
function menuSectionFooter ()
|
||||
{
|
||||
echo ' </TD>' .
|
||||
' </TR>' .
|
||||
'</TABLE>';
|
||||
}
|
||||
|
||||
function qfMenu ()
|
||||
{
|
||||
menuSectionHeader ("Project", 'white', menuHeadColor, menuBgColor);
|
||||
menuItemLink ("/", "Latest News");
|
||||
menuItemLink ("/news.php", "Old News");
|
||||
menuItemLink ("/files.php", "Downloads");
|
||||
menuItemLink ("http://sourceforge.net/bugs/?group_id=882", "Bug Reports");
|
||||
menuItemLink ("http://sourceforge.net/mail/?group_id=882", "Mailing Lists");
|
||||
menuItemLink ("/board/", "Web Forum");
|
||||
menuSectionFooter ();
|
||||
}
|
||||
|
||||
function develMenu ()
|
||||
{
|
||||
menuSectionHeader ("Developers", 'white', menuHeadColor, menuBgColor);
|
||||
menuItemLink ("http://sourceforge.net/cvs/?group_id=882", "CVS Access");
|
||||
menuItemLink ("/devtools.php", "Developer Tools");
|
||||
menuItemLink ("/plans.php", "Developer Plans");
|
||||
menuItemLink ("/progress.php", "Progress");
|
||||
menuItemLink ("/sotc/", "State of the Code");
|
||||
menuItemLink ("/research/", "Research Center");
|
||||
// menuItemLink ("http://sourceforge.net/patch/?group_id=882", "Patch Manager");
|
||||
// menuItemLink ("http://sourceforge.net/support/?group_id=882", "Support Manager");
|
||||
menuItemLink ("http://sourceforge.net/pm/?group_id=882", "Task Manager");
|
||||
menuSectionFooter ();
|
||||
}
|
||||
|
||||
function sfMenu ()
|
||||
{
|
||||
menuSectionHeader ("SourceForge", 'white', menuHeadColor, menuBgColor);
|
||||
menuItemLink ("http://sourceforge.net/", "Homepage");
|
||||
menuItemLink ("http://sourceforge.net/snippet/", "Code Snippet Library");
|
||||
menuItemLink ("http://sourceforge.net/softwaremap/", "Software Map");
|
||||
menuItemLink ("http://sourceforge.net/new/", "New Releases");
|
||||
menuItemLink ("http://sourceforge.net/docs/site/", "Site Documentation");
|
||||
menuItemLink ("http://sourceforge.net/top/", "Top Projects");
|
||||
menuItemLink ("http://sourceforge.net/mirrors/", "Other Site Mirrors");
|
||||
menuSectionFooter ();
|
||||
}
|
||||
|
||||
function searchMenu ()
|
||||
{
|
||||
menuSectionHeader ("Search", 'white', menuHeadColor, menuBgColor);
|
||||
echo '<CENTER><FONT size="-2">' .
|
||||
'<FORM action="search.php" method="POST">' .
|
||||
' <SELECT name="type_of_search">' .
|
||||
' <OPTION value="news">News</OPTION>' .
|
||||
' <OPTION value="site">Site</OPTION>' .
|
||||
' <OPTION value="bugs">Bug Tracking</OPTION>' .
|
||||
' <OPTION value="lists">Mailing Lists</OPTION>' .
|
||||
' <OPTION value="patches">Patches</OPTION>' .
|
||||
' </SELECT>' .
|
||||
' <BR>' .
|
||||
' <INPUT TYPE="CHECKBOX" NAME="exact" VALUE="1" CHECKED> Require Exact Match' .
|
||||
' <BR>' .
|
||||
' <INPUT TYPE="HIDDEN" NAME="forum_id" VALUE="">' .
|
||||
' <INPUT TYPE="HIDDEN" NAME="is_bug_page" VALUE="">' .
|
||||
' <INPUT TYPE="HIDDEN" NAME="group_id" VALUE="882">' .
|
||||
' <INPUT TYPE="text" NAME="words" SIZE="15" VALUE="">' .
|
||||
' <BR>' .
|
||||
' <INPUT TYPE="submit" NAME="Search" VALUE="Search">' .
|
||||
'</FORM></FONT>' .
|
||||
'</CENTER>';
|
||||
menuSectionFooter ();
|
||||
}
|
||||
|
||||
qfMenu ();
|
||||
develMenu ();
|
||||
// sfMenu ();
|
||||
searchMenu ();
|
||||
?>
|
||||
|
|
|
@ -1,16 +1,16 @@
|
|||
<!-- Content End -->
|
||||
</TD>
|
||||
<? tableSpacer( 9, 9, 1, "black"); ?>
|
||||
<? tableSpacer (9, 9, 1, "black"); ?>
|
||||
</TR>
|
||||
<TR>
|
||||
<? tableSpacer( 9, 9, 3, "black"); ?>
|
||||
<? tableSpacer (9, 9, 3, "black"); ?>
|
||||
</TR>
|
||||
<? tableFooter(); ?>
|
||||
</TD>
|
||||
</TR>
|
||||
<TR vAlign="top">
|
||||
<TD colSpan="2">
|
||||
<TABLE width="100%" border="0" cellSpacing="0" cellPadding="2" bgColor="#4b4f66">
|
||||
<TABLE width="100%" border="0" cellSpacing="0" cellPadding="2" bgColor="<? echo menuBgColor; ?>">
|
||||
<TR>
|
||||
<TD align="center">
|
||||
<SPAN class="titlebar">
|
||||
|
|
|
@ -2,37 +2,37 @@
|
|||
$siteName = "The QuakeForge Project";
|
||||
define('siteHome', "/home/groups/quake/htdocs");
|
||||
|
||||
require(siteHome ."/parts/library.php"); // Load function library
|
||||
require siteHome . "/parts/library.php"; // Load function library
|
||||
if ($need) {
|
||||
need ($need);
|
||||
unset ($need);
|
||||
}
|
||||
need ('table');
|
||||
require (siteHome ."/parts/head.php"); // Load the HEAD and open BODY
|
||||
require (siteHome ."/parts/topstrip.php"); // Display top strip
|
||||
require (siteHome ."/parts/titletable.php");// Display main title w/ logos
|
||||
require siteHome . "/parts/head.php"; // Load the HEAD and open BODY
|
||||
require siteHome . "/parts/topstrip.php"; // Display top strip
|
||||
require siteHome . "/parts/titletable.php"; // Display main title w/ logos
|
||||
?>
|
||||
<TABLE width="100%" cellSpacing="0" cellPadding="0" border="0">
|
||||
<TR vAlign="top">
|
||||
<TD bgColor="<? echo menuBgColor; ?>">
|
||||
<? include(siteHome ."/parts/menu.php"); /* menus */ ?>
|
||||
<? include siteHome . "/parts/menu.php"; ?>
|
||||
</TD>
|
||||
<TD width="100%">
|
||||
<? tableHeader("100%", "black"); ?>
|
||||
<? tableHeader ("100%", "black"); ?>
|
||||
<TR>
|
||||
<? tableSpacer( 9, 9, 3, "black"); ?>
|
||||
<? tableSpacer (9, 9, 3, "black"); ?>
|
||||
</TR>
|
||||
<TR>
|
||||
<? tableSpacer( 9, 9, 1, "black"); ?>
|
||||
<? tableSpacer (9, 9, 1, "black"); ?>
|
||||
<TD>
|
||||
<? require(siteHome ."/parts/topmain.php"); ?>
|
||||
<? require siteHome . "/parts/topmain.php"; ?>
|
||||
</TD>
|
||||
<? tableSpacer( 9, 9, 1, "black"); ?>
|
||||
<? tableSpacer (9, 9, 1, "black"); ?>
|
||||
</TR>
|
||||
<TR>
|
||||
<? tableSpacer( 18, 9, 3, "black"); ?>
|
||||
<? tableSpacer (18, 9, 3, "black"); ?>
|
||||
</TR>
|
||||
<TR>
|
||||
<? tableSpacer( 9, 9, 1, "black"); ?>
|
||||
<? tableSpacer (9, 9, 1, "black"); ?>
|
||||
<TD>
|
||||
<!-- Content Start -->
|
||||
|
|
|
@ -1,24 +1,25 @@
|
|||
<!-- top title table -->
|
||||
<? need ('table'); ?>
|
||||
<TABLE width="100%" border=0 cellspacing=0 cellpadding=0 bgcolor="" valign="center">
|
||||
<TR vAlign="top" bgColor="<? echo menuBgColor ?>">
|
||||
<? tableSpacer (3, 0, 4, menuBgColor); ?>
|
||||
<TABLE width="100%" border="0" cellSpacing="0" cellPadding="0" bgColor="<? echo menuBgColor ?>" vAlign="center">
|
||||
<TR vAlign="top">
|
||||
<? tableSpacer (3, 0, 6, menuBgColor); ?>
|
||||
</TR>
|
||||
<TR valign="top" bgcolor="<? echo menuBgColor ?>">
|
||||
<TR vAlign="top">
|
||||
<? tableSpacer (0, 1, 1, menuBgColor); ?>
|
||||
<TD>
|
||||
<IMG src="/img/logos/qf-logo.png" alt="QuakeForge" hSpace=0 vSpace=0 border=0 width="70" height="70">
|
||||
<TD align="center" vAlign="center"><!-- Project logo -->
|
||||
<IMG src="/img/logos/qf-logo.png" alt="QuakeForge" border="0" width="70" height="70">
|
||||
</TD>
|
||||
<? tableSpacer (0, 5, 1, menuBgColor); ?>
|
||||
<TD width="99%"><!-- right of logo -->
|
||||
<a href="http://sourceforge.net/"><IMG src="http://sourceforge.net/sflogo.php?group_id=882&type=1" align="right" alt="SourceForge" hspace=20 vspace=20 border=0 width="88" height="31"></A>
|
||||
<BR>
|
||||
<SPAN class="mainTitle"><? echo $siteName ?></SPAN>
|
||||
<TD width="100%" vAlign="center"><!--Site name -->
|
||||
<SPAN class="mainTitle"><? echo $siteName ?></SPAN>
|
||||
</TD>
|
||||
<!-- right of logo -->
|
||||
<TD align="center" vAlign="center"><!-- SourceForge logo -->
|
||||
<A href="http://sourceforge.net/"><IMG src="http://sourceforge.net/sflogo.php?group_id=882&type=1" alt="SourceForge" border="0" width="88" height="31"></A>
|
||||
</TD>
|
||||
<? tableSpacer (0, 20, 1, menuBgColor); ?>
|
||||
</TR>
|
||||
<TR>
|
||||
<? tableSpacer (2, 0, 2, "black"); ?>
|
||||
<? tableSpacer (2, 0, 6, "black"); ?>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<!-- end top title table -->
|
||||
|
|
|
@ -17,11 +17,11 @@
|
|||
'<TR>';
|
||||
tableSpacer (1, 1, 1, "white");
|
||||
echo '<TD>';
|
||||
iconLink ('http://sourceforge.net/project/?group_id=882', '/img/icons/anvil.png', 'SourceForge', isFocused($focused, 'summary'));
|
||||
iconLink ('http://sourceforge.net/projects/quake/', '/img/icons/anvil.png', 'SourceForge', isFocused($focused, 'summary'));
|
||||
iconLink ('/', '/img/icons/home.png', 'Homepage', isFocused($focused, 'home'));
|
||||
iconLink ('http://sourceforge.net/bugs/?group_id=882', '/img/icons/bugs.png', 'Bugs', isFocused($focused, 'bugs'));
|
||||
// iconLink ('http://sourceforge.net/support/?group_id=882', '/img/icons/support.png', 'Support', isFocused($focused, 'support'));
|
||||
iconLink ('http://sourceforge.net/patch/?group_id=882', '/img/icons/patch.png', 'Patches', isFocused($focused, 'patch'));
|
||||
// iconLink ('http://sourceforge.net/patch/?group_id=882', '/img/icons/patch.png', 'Patches', isFocused($focused, 'patch'));
|
||||
iconLink ('http://sourceforge.net/mail/?group_id=882', '/img/icons/mail.png', 'Lists', isFocused($focused, 'mail'));
|
||||
iconLink ('http://sourceforge.net/pm/?group_id=882', '/img/icons/tasks.png', 'Tasks', isFocused($focused, 'tasks'));
|
||||
// iconLink ('http://sourceforge.net/survey/?group_id=882', '/img/icons/survey.png', 'Surveys', isFocused($focused, 'survey'));
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<!-- top strip -->
|
||||
<TABLE width="100%" border=0 cellspacing=0 cellpadding=2 bgcolor="737b9c">
|
||||
<TR>
|
||||
<TD>
|
||||
<TABLE width="100%" border="0" cellSpacing="0" cellPadding="2" bgColor="#737b9c">
|
||||
<TR vAlign="center">
|
||||
<TD align="left">
|
||||
<SPAN class=maintitlebar>
|
||||
<A class=maintitlebar href="/"><B>Home</B></A> |
|
||||
<A class=maintitlebar href="/about.php"><B>About</B></A> |
|
||||
|
@ -10,7 +10,7 @@
|
|||
<A class=maintitlebar href="/members/"><B>Members</B></A>
|
||||
</SPAN>
|
||||
</TD>
|
||||
<TD ALIGN="right">
|
||||
<TD align="right">
|
||||
<A class=maintitlebar href="http://sourceforge.net/"><B>SourceForge member</B></a>
|
||||
</TD>
|
||||
</TR>
|
||||
|
|
Loading…
Reference in a new issue