SourceForge logo
SourceForge logo
Menu

phpwiki-checkins

From: Geoffrey T. D. <da...@us...> - 2002年10月19日 16:40:32
Update of /cvsroot/phpwiki/phpwiki/lib
In directory usw-pr-cvs1:/tmp/cvs-serv26472/lib
Modified Files:
	main.php 
Log Message:
Fix for remove page bug when USE_PATH_INFO is false.
Index: main.php
===================================================================
RCS file: /cvsroot/phpwiki/phpwiki/lib/main.php,v
retrieving revision 1.86
retrieving revision 1.87
diff -u -2 -b -p -d -r1.86 -r1.87
--- main.php	15 Oct 2002 18:42:21 -0000	1.86
+++ main.php	19 Oct 2002 16:40:29 -0000	1.87
@@ -402,5 +402,26 @@ class WikiRequest extends Request {
 }
 }
+ elseif ($this->isPost()) {
+ /*
+ * In general, for security reasons, HTTP_GET_VARS should be ignored
+ * on POST requests, but we make an exception here (only for pagename).
+ *
+ * The justifcation for this hack is the following
+ * asymmetry: When POSTing with USE_PATH_INFO set, the
+ * pagename can (and should) be communicated through the
+ * request URL via PATH_INFO. When POSTing with
+ * USE_PATH_INFO off, this cannot be done --- the only way
+ * to communicate the pagename through the URL is via
+ * QUERY_ARGS (HTTP_GET_VARS).
+ */
+ global $HTTP_GET_VARS;
+ if (isset($HTTP_GET_VARS['pagename'])) { 
+ return $HTTP_GET_VARS['pagename'];
+ }
+ }
 
+ /*
+ * Support for PhpWiki 1.2 style requests.
+ */
 $query_string = $this->get('QUERY_STRING');
 if (preg_match('/^[^&=]+$/', $query_string)) {
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.
Thanks for helping keep SourceForge clean.
X





Briefly describe the problem (required):
Upload screenshot of ad (required):
Select a file, or drag & drop file here.
Screenshot instructions:

Click URL instructions:
Right-click on the ad, choose "Copy Link", then paste here →
(This may not be possible with some types of ads)

More information about our ad policies

Ad destination/click URL:

AltStyle によって変換されたページ (->オリジナル) /