diff options
| author | donncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36> | 2008-04-04 16:44:15 +0000 |
|---|---|---|
| committer | donncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36> | 2008-04-04 16:44:15 +0000 |
| commit | 7740e89de3e1bc0cc636120e3ca8ab9e97e4d3cc (patch) | |
| tree | c6fd23b598f3994eddb18cb1c0f2e8d95ff054fa /wp-admin/setup-config.php | |
| parent | f650f48c048bfbbb2ae702b6425d87e39358d748 (diff) | |
| download | wordpress-mu-7740e89de3e1bc0cc636120e3ca8ab9e97e4d3cc.tar.gz wordpress-mu-7740e89de3e1bc0cc636120e3ca8ab9e97e4d3cc.tar.xz wordpress-mu-7740e89de3e1bc0cc636120e3ca8ab9e97e4d3cc.zip | |
Merged with WordPress 2.5, unstable, only for testing
git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@1218 7be80a69-a1ef-0310-a953-fb0f7c49ff36
Diffstat (limited to 'wp-admin/setup-config.php')
| -rw-r--r-- | wp-admin/setup-config.php | 77 |
1 files changed, 16 insertions, 61 deletions
diff --git a/wp-admin/setup-config.php b/wp-admin/setup-config.php index 99af3b4..796ca07 100644 --- a/wp-admin/setup-config.php +++ b/wp-admin/setup-config.php @@ -1,6 +1,9 @@ <?php die(); define('WP_INSTALLING', true); +//These two defines are required to allow us to use require_wp_db() to load the database class while being wp-content/wp-db.php aware +define('ABSPATH', dirname(dirname(__FILE__)).'/'); +define('WPINC', 'wp-includes'); require_once('../wp-includes/compat.php'); require_once('../wp-includes/functions.php'); @@ -11,7 +14,7 @@ if (!file_exists('../wp-config-sample.php')) $configFile = file('../wp-config-sample.php'); -if ( !is_writable('../')) +if ( !is_writable('../')) wp_die("Sorry, I can't write to the directory. You'll have to either change the permissions on your WordPress directory or create your wp-config.php manually."); // Check if wp-config.php has been created @@ -29,60 +32,10 @@ function display_header(){ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> -<title>WordPress › Setup Configuration File</title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> -<style media="screen" type="text/css"> - <!-- - html { - background: #eee; - } - body { - background: #fff; - color: #000; - font-family: Georgia, "Times New Roman", Times, serif; - margin-left: 20%; - margin-right: 20%; - padding: .2em 2em; - } - - h1 { - color: #006; - font-size: 18px; - font-weight: lighter; - } - - h2 { - font-size: 16px; - } - - p, li, dt { - line-height: 140%; - padding-bottom: 2px; - } +<title>WordPress › Setup Configuration File</title> +<link rel="stylesheet" href="<?php echo $admin_dir; ?>css/install.css" type="text/css" /> - ul, ol { - padding: 5px 5px 5px 20px; - } - #logo { - margin-bottom: 2em; - } - .step a, .step input { - font-size: 2em; - } - td input { - font-size: 1.5em; - } - .step, th { - text-align: right; - } - #footer { - text-align: center; - border-top: 1px solid #ccc; - padding-top: 1em; - font-style: italic; - } - --> - </style> </head> <body> <h1 id="logo"><img alt="WordPress" src="images/wordpress-logo.png" /></h1> @@ -103,17 +56,18 @@ switch($step) { <li>Table prefix (if you want to run more than one WordPress in a single database) </li> </ol> <p><strong>If for any reason this automatic file creation doesn't work, don't worry. All this does is fill in the database information to a configuration file. You may also simply open <code>wp-config-sample.php</code> in a text editor, fill in your information, and save it as <code>wp-config.php</code>. </strong></p> -<p>In all likelihood, these items were supplied to you by your ISP. If you do not have this information, then you will need to contact them before you can continue. If you’re all ready, <a href="setup-config.php?step=1">let’s go</a>! </p> +<p>In all likelihood, these items were supplied to you by your ISP. If you do not have this information, then you will need to contact them before you can continue. If you’re all ready…</p> + +<p><a href="setup-config.php?step=1" class="button">Let’s go!</a></p> <?php break; case 1: display_header(); ?> -</p> <form method="post" action="setup-config.php?step=2"> <p>Below you should enter your database connection details. If you're not sure about these, contact your host. </p> - <table> + <table class="form-table"> <tr> <th scope="row">Database Name</th> <td><input name="dbname" type="text" size="25" value="wordpress" /></td> @@ -141,7 +95,7 @@ switch($step) { </tr> </table> <h2 class="step"> - <input name="submit" type="submit" value="Submit" /> + <input name="submit" type="submit" value="Submit" class="button" /> </h2> </form> <?php @@ -162,7 +116,7 @@ switch($step) { define('DB_HOST', $dbhost); // We'll fail here if the values are no good. - require_once('../wp-includes/wp-db.php'); + require_wp_db(); if ( !empty($wpdb->error) ) wp_die($wpdb->error->get_error_message()); @@ -191,14 +145,15 @@ switch($step) { } fclose($handle); chmod('../wp-config.php', 0666); - + display_header(); ?> -<p>All right sparky! You've made it through this part of the installation. WordPress can now communicate with your database. If you are ready, time now to <a href="install.php">run the install!</a></p> +<p>All right sparky! You've made it through this part of the installation. WordPress can now communicate with your database. If you are ready, time now to…</p> + +<p><a href="install.php" class="button">Run the install</a></p> <?php break; } ?> -<p id="footer"><a href="http://wordpress.org/">WordPress</a>, personal publishing platform.</p> </body> </html> |
