cvs: php-hosts-web /msgboard list.php post.php preview.php shared-msgboard.inc /msgboard/etc delete.php edit.php index.php toolbar.php
| From: | jim winstead | Date: | Mon, 22 Apr 2002 00:48:39 +0000 |
| Subject: | cvs: php-hosts-web /msgboard list.php post.php preview.php shared-msgboard.inc /msgboard/etc delete.php edit.php index.php toolbar.php | ||
| Groups: | php.mirrors | ||
| Request: | Send a blank email to php-mirrors+get-9741@lists.php.net to get a copy of this message | ||
jimw Sun Apr 21 20:48:39 2002 EDT
Removed files:
/php-hosts-web/msgboard/etc toolbar.php
Modified files:
/php-hosts-web/msgboard list.php post.php preview.php
shared-msgboard.inc
/php-hosts-web/msgboard/etc delete.php edit.php index.php
Log:
clean out more unused code, eliminate more variables
Index: php-hosts-web/msgboard/list.php
diff -u php-hosts-web/msgboard/list.php:1.1 php-hosts-web/msgboard/list.php:1.2
--- php-hosts-web/msgboard/list.php:1.1 Sun Apr 21 16:58:04 2002
+++ php-hosts-web/msgboard/list.php Sun Apr 21 20:48:38 2002
@@ -6,7 +6,7 @@
commonHeader("List Messages: $groupname");
title("List Messages");
else:
- Header("Location: $ROOT_URL");
+ Header("Location: index.php");
exit;
endif;
else:
Index: php-hosts-web/msgboard/post.php
diff -u php-hosts-web/msgboard/post.php:1.3 php-hosts-web/msgboard/post.php:1.4
--- php-hosts-web/msgboard/post.php:1.3 Sun Apr 21 20:42:03 2002
+++ php-hosts-web/msgboard/post.php Sun Apr 21 20:48:38 2002
@@ -23,7 +23,7 @@
$message = addslashes($message);
}
- $query = "INSERT INTO $TABLE_MSGS SET
date=NOW(),subgroup=$subgroup,parent=$parent,type=$type,subj='$subj',email='$email',name='$name',message='$message')";
+ $query = "INSERT INTO $TABLE_MSGS SET
date=NOW(),subgroup=$subgroup,parent=$parent,subj='$subj',email='$email',name='$name',message='$message')";
mysql_query($query);
$id = mysql_insert_id();
@@ -68,7 +68,6 @@
onReset="return confirm('Really erase all fields and start over?')"
onSubmit="return checkFields();">
<input TYPE="hidden" NAME="mode" value="preview">
-<INPUT TYPE="hidden" NAME="type" value="<? echo
$HTML;?>">
<INPUT TYPE="hidden" NAME="subgroup" value=<? echo $subgroup;?> >
<input TYPE="hidden" NAME="MAX_FILE_SIZE" VALUE="<? echo
$MAX_DOC_SIZE;?>">
<?php
Index: php-hosts-web/msgboard/preview.php
diff -u php-hosts-web/msgboard/preview.php:1.3 php-hosts-web/msgboard/preview.php:1.4
--- php-hosts-web/msgboard/preview.php:1.3 Sun Apr 21 20:42:03 2002
+++ php-hosts-web/msgboard/preview.php Sun Apr 21 20:48:38 2002
@@ -30,7 +30,6 @@
?>
<form method=post action="post.php">
<input type=hidden name="mode" value="post">
-<input type=hidden name="type" value=<? echo $type;?>>
<input type=hidden name="parent" value=<? echo $parent;?>>
<input type=hidden name="name" value="<? qecho($name);?>">
<input type=hidden name="email" value="<? qecho($email);?>">
Index: php-hosts-web/msgboard/shared-msgboard.inc
diff -u php-hosts-web/msgboard/shared-msgboard.inc:1.6
php-hosts-web/msgboard/shared-msgboard.inc:1.7
--- php-hosts-web/msgboard/shared-msgboard.inc:1.6 Sun Apr 21 20:42:03 2002
+++ php-hosts-web/msgboard/shared-msgboard.inc Sun Apr 21 20:48:38 2002
@@ -48,20 +48,10 @@
/* Setup the directory and URL structures: */
-$ROOT_DIR=$SERVER['DOCUMENT_ROOT'].'/msgboard';
-$ROOT_URL="http://hosts.php.net/msgboard";
$HOME_URL="http://hosts.php.net";
$GIFS="$ROOT_URL/gifs";
$STAFF_URL="http://hosts.php.net/staff";
-$MOD_URL="$ROOT_URL/etc";
-$MOD_DIR="$ROOT_DIR/etc";
$TOOLBAR="toolbar.php";
-$MOD_TOOLBAR="$MOD_DIR/toolbar.php";
-
-/* Obsolete variables, kept for backwards compatability */
-
-$TXT=1;
-$HTML=2;
/* If $USE_SUBGROUP = true, you will have subgroups, or categories, defined for each message.
Write your own code to convert between the subgroup number and the subgroup name!
@@ -160,7 +150,7 @@
* Threads the message headers
* if $mode=1, it's the moderator function
*/
- global $DBASE, $TABLE_MSGS, $ROOT_DIR, $ROOT_URL, $MOD_URL;
+ global $DBASE, $TABLE_MSGS;
global $BGCOLOR, $DATE_FORMAT,$jjj;
$query="select * from $TABLE_MSGS where parent=$parent and subgroup=$subgroup order by date
desc";
$q1=mysql_db_query($DBASE, $query);
@@ -257,15 +247,6 @@
echo "</TD></TR>\n";
};
-function showDisclaimer () {
-/*
- * Displays the download disclaimer message - a good idea ...!
- */
- echo "<B>You are about to download a document.</B> We do not claim any
responsibility for the content of the following file, nor does we guarantee that the file will not
harm your system.<P>\n";
- echo "If you have any problems with the file, please send your comments to the person who
posted the file.<P>\n";
- echo "If you are unable to view or open the file on your machine (because you don't have
the appropriate application, for example), please ask the person who posted the file to convert it
to another format.\n";
-};
-
function deleteMsg ($id) {
/*
* Deletes a posted message, and any attachments
@@ -282,14 +263,6 @@
mysql_query("update $TABLE_MSGS set parent=$parent where parent=$id");
return($subj);
endif;
-};
-
-function commonModHeader ($x) {
- commonHeader($x);
-};
-
-function commonModFooter () {
- commonFooter();
};
?>
Index: php-hosts-web/msgboard/etc/delete.php
diff -u php-hosts-web/msgboard/etc/delete.php:1.1 php-hosts-web/msgboard/etc/delete.php:1.2
--- php-hosts-web/msgboard/etc/delete.php:1.1 Sun Apr 21 16:58:05 2002
+++ php-hosts-web/msgboard/etc/delete.php Sun Apr 21 20:48:39 2002
@@ -22,7 +22,6 @@
endwhile;
echo "</UL>";
echo "Done: <B>$num</B> messages deleted.<P>";
- staffToolbar();
commonFooter();
exit;
endif;
Index: php-hosts-web/msgboard/etc/edit.php
diff -u php-hosts-web/msgboard/etc/edit.php:1.2 php-hosts-web/msgboard/etc/edit.php:1.3
--- php-hosts-web/msgboard/etc/edit.php:1.2 Sun Apr 21 20:14:00 2002
+++ php-hosts-web/msgboard/etc/edit.php Sun Apr 21 20:48:39 2002
@@ -21,7 +21,6 @@
echo "<FONT SIZE=+1><b>Message edited.</b></FONT><P>\n";
echo "<CENTER>\n";
- staffToolbar();
echo "</CENTER>\n";
commonFooter();
exit;
Index: php-hosts-web/msgboard/etc/index.php
diff -u php-hosts-web/msgboard/etc/index.php:1.1 php-hosts-web/msgboard/etc/index.php:1.2
--- php-hosts-web/msgboard/etc/index.php:1.1 Sun Apr 21 16:58:05 2002
+++ php-hosts-web/msgboard/etc/index.php Sun Apr 21 20:48:39 2002
@@ -60,6 +60,5 @@
$i++;
endwhile;
echo "</TABLE>\n";
-staffToolbar();
commonFooter();
?>