summaryrefslogtreecommitdiffstats
path: root/app.php
diff options
context:
space:
mode:
authordonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2007-02-26 14:03:58 +0000
committerdonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2007-02-26 14:03:58 +0000
commitce8693de30e8da06a8a4982e321f0a33fbeee979 (patch)
treec80ea3a19e84d0da5a48815fe4457e46f784e193 /app.php
parent132f53ddaeb250222a4ac85ebc0bf4dd780db60e (diff)
downloadwordpress-mu-ce8693de30e8da06a8a4982e321f0a33fbeee979.tar.gz
wordpress-mu-ce8693de30e8da06a8a4982e321f0a33fbeee979.tar.xz
wordpress-mu-ce8693de30e8da06a8a4982e321f0a33fbeee979.zip
WP Merge to rev 4950
git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@900 7be80a69-a1ef-0310-a953-fb0f7c49ff36
Diffstat (limited to 'app.php')
-rw-r--r--app.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/app.php b/app.php
index 4d868bb..7c2d827 100644
--- a/app.php
+++ b/app.php
@@ -12,7 +12,9 @@ define('APP_REQUEST', true);
require_once('wp-config.php');
require_once('wp-includes/post-template.php');
-$use_querystring = 1;
+// Attempt to automatically detect whether to use querystring
+// or PATH_INFO, based on our environment:
+$use_querystring = $wp_version == 'MU' ? 1 : 0;
// If using querystring, we need to put the path together manually:
if ($use_querystring) {
@@ -556,7 +558,7 @@ EOD;
elseif ( isset( $_SERVER['HTTP_TITLE'] ) )
$slug = sanitize_file_name( $_SERVER['HTTP_TITLE'] );
elseif ( empty( $slug ) ) // just make a random name
- $slug = substr( md5( uniqid( microtime() ) ), 0, 7);;
+ $slug = substr( md5( uniqid( microtime() ) ), 0, 7);
$ext = preg_replace( '|.*/([a-z]+)|', '$1', $_SERVER['CONTENT_TYPE'] );
$slug = "$slug.$ext";
$file = wp_upload_bits( $slug, NULL, $bits);