Warning!
Installing to http://localhost/ is not supported. Please use http://localhost.localdomain/ instead.
" ); } define('WP_INSTALLING', true); define('WP_FIRST_INSTALL', true); $dirs = array( dirname(__FILE__), dirname(__FILE__) . "/wp-content/" ); function printheader() { ?>
If you post a message to the µ support forum at http://mu.wordpress.org/forums/ then copy and paste the following information into your message:
"; print ""; print ""; } function do_htaccess( $oldfilename, $newfilename, $base, $url ) { // remove ending slash from $base and $url $htaccess = ''; if( substr($base, -1 ) == '/') { $base = substr($base, 0, -1); } if( substr($url, -1 ) == '/') { $url = substr($url, 0, -1); } $err = ''; if( is_file( $oldfilename ) ) { $fp = @fopen( $oldfilename, "r" ); if( $fp ) { while( !feof( $fp ) ) { $htaccess .= fgets( $fp, 4096 ); } fclose( $fp ); $htaccess = str_replace( "BASE", $base, $htaccess ); if( touch( $newfilename ) ) { $fp = fopen( $newfilename, "w" ); if( $fp ) { fwrite( $fp, $htaccess ); fclose( $fp ); } else { $err = "could not open $newfilename for writing"; } } else { $err = "could not open $newfilename for writing"; } } else { $err = "could not open $oldfilename for reading"; } } else { $err = "$oldfilename not found"; } if( $err != '' ) { print "
ERROR: $err
"; clearstatcache(); $files = array( "htaccess.dist", ".htaccess" ); foreach ( (array) $files as $val ) { $stats = @stat( $val ); if( $stats ) { print "$val
"; print " uid/gid: " . $stats[ 'uid' ] . "/" . $stats[ 'gid' ] . "
\n"; print " size: " . $stats[ 'size' ] . "
"; print " perms: " . substr( sprintf('%o', fileperms( $val ) ), -4 ) . "
"; print " readable: "; print is_readable( $val ) == true ? "yes" : "no"; print "
"; print " writeable: "; print is_writeable( $val ) == true ? "yes" : "no"; print "
"; } elseif( file_exists( $val ) == false ) { print "$val
"; print " FILE NOT FOUND: $val
"; } } print "
There was a problem creating the .htaccess file.
"; print "Error: "; if( $err == "could not open $newfilename for writing" ) { print "Could Not Write To $newfilename."; } elseif( $err == "could not open $oldfilename for reading" ) { print "I could not read from $oldfilename. "; } elseif( $err == "$oldfilename not found" ) { print "The file, $oldfilename, is missing."; } print "
"; filestats( $err ); print "Please ensure that the webserver can write to this directory.
"; print "If you use Cpanel then read this post. Cpanel creates files that I need to overwrite and you have to fix that.
"; print "If all else fails then you'll have to create it by hand:"; print "
One or more of the directories must be made writeable by the webserver. You will be reminded to reset the permissions at the end of the install.
Please chmod 777 or directory-name
chown that directory to the user the web server runs as (usually nobody, apache, or www-data)
Refresh this page when you're done!
Quick fix:
chmod 777
A file with the name '.htaccess' already exists in this directory and I cannot write to it. Please ftp to the server and delete this file from this directory!
Offending file:
Welcome to WordPress µ. I will help you install this software by asking you a few questions and asking that you change the permissions on a few directories so I can create configuration files and make a directory to store all your uploaded files.
If you have installed the single-blog version of WordPress before, please note that the WordPress µ installer is different and trying to create the configuration file wp-config.php youself may result in a broken site. It's much easier to use this installer to get the job done.
wp_ which may conflict with an existing WordPress install.mod_rewrite module is disabled ask your administrator to enable that module, or look at the Apache documentation or elsewhere for help setting it up.";
if( function_exists( "apache_get_modules" ) ) {
$modules = apache_get_modules();
if( in_array( "mod_rewrite", $modules ) == false ) {
echo "Warning! It looks like mod_rewrite is not installed.
" . $mod_rewrite_msg; } } else { ?>Please make sure mod_rewrite is installed as it will be activated at the end of this install.
Congratulations!
Your WordPress µ site has been configured.
You can log in using the username "admin" and password
5, 'httpversion' => '1.1' ) ); if( is_object( $page ) && is_wp_error( $page ) ) { foreach ( $page->get_error_messages() as $err ) $errstr = $err; } elseif( $page[ 'response' ][ 'code' ] == 200 ) { $vhost_ok = true; } } else { $fp = fsockopen( $hostname, 80, $errno, $errstr, 5 ); // Very random hostname! if( $fp ) { $vhost_ok = true; fclose( $fp ); } } if( !$vhost_ok ) { echo "To use the subdomain feature of WordPress MU you must have a wildcard entry in your dns. The installer attempted to contact a random hostname ($hostname) on your domain but failed. It returned this error message:
$errstr
From the README.txt:
"; echo "If you want to host blogs of the form http://blog.domain.tld/ where domain.tld is the domain name of your machine then you must add a wildcard record to your DNS records."; echo "
This usually means adding a '*' hostname record pointing at your webserver in your DNS configuration tool. Matt has a more detailed explanation on his blog. If you still have problems, these forum messages may help.
You can still use your site but any subdomain you create may not be accessible. This check is not foolproof so ignore if you know your dns is correct.
"; } } ?>Please remember to reset the permissions on the following directories:
You can probably use the following command to fix the permissions but check with your host if it doubt:
chmod 755
Thanks for installing WordPress µ!
Donnchawpmu version:
WordPress µ strips the string "www" from the URLs of sites using this software. It is still possible to visit your site using the "www" prefix with an address like but any links will not have the "www" prefix. They will instead point at .
The preferred method of hosting blogs is without the "www" prefix as it's more compact and simple.
You can still use "" and URLs like "www.blog1." to address your site and blogs after installation but internal links will use the format.
www. is depreciated has a lot more information on why 'www.' isn't needed any more.