Changeset 4259 for trunk/wp-admin/install.php
- Timestamp:
- 09/28/2006 05:35:59 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/install.php
r4006 r4259 2 2 define('WP_INSTALLING', true); 3 3 if (!file_exists('../wp-config.php')) 4 die("There doesn't seem to be a <code>wp-config.php</code> file. I need this before we can get started. Need more help? <a href='http://wordpress.org/docs/faq/#wp-config'>We got it</a>. You can <a href='setup-config.php'>create a <code>wp-config.php</code> file through a web interface</a>, but this doesn't work for all server setups. The safest way is to manually create the file.");4 die("There doesn't seem to be a <code>wp-config.php</code> file. I need this before we can get started. Need more help? <a href='http://codex.wordpress.org/Installing_WordPress#Step_3:_Set_up_wp-config.php'>We got it</a>. You can <a href='setup-config.php'>create a <code>wp-config.php</code> file through a web interface</a>, but this doesn't work for all server setups. The safest way is to manually create the file."); 5 5 6 6 require_once('../wp-config.php'); … … 14 14 ?> 15 15 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 16 <html xmlns="http://www.w3.org/1999/xhtml" >16 <html xmlns="http://www.w3.org/1999/xhtml" <?php language_attributes(); ?>> 17 17 <head> 18 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 18 19 <title><?php _e('WordPress › Installation'); ?></title> 19 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 20 <style media="screen" type="text/css"> 21 <!-- 22 html { 23 background: #eee; 24 } 25 body { 26 background: #fff; 27 color: #000; 28 font-family: Georgia, "Times New Roman", Times, serif; 29 margin-left: 20%; 30 margin-right: 20%; 31 padding: .2em 2em; 32 } 33 34 h1 { 35 color: #006; 36 font-size: 18px; 37 font-weight: lighter; 38 } 39 40 h2 { 41 font-size: 16px; 42 } 43 44 p, li, dt { 45 line-height: 140%; 46 padding-bottom: 2px; 47 } 48 49 ul, ol { 50 padding: 5px 5px 5px 20px; 51 } 52 #logo { 53 margin-bottom: 2em; 54 } 55 .step a, .step input { 56 font-size: 2em; 57 } 58 td input { 59 font-size: 1.5em; 60 } 61 .step, th { 62 text-align: right; 63 } 64 #footer { 65 text-align: center; 66 border-top: 1px solid #ccc; 67 padding-top: 1em; 68 font-style: italic; 69 } 70 --> 71 </style> 20 <link rel="stylesheet" href="install.css?version=<?php bloginfo('version'); ?>" type="text/css" /> 21 <?php if ( ('rtl' == $wp_locale->text_direction) ) : ?> 22 <link rel="stylesheet" href="install-rtl.css?version=<?php bloginfo('version'); ?>" type="text/css" /> 23 <?php endif; ?> 72 24 </head> 73 25 <body> … … 78 30 79 31 switch($step) { 80 81 32 case 0: 82 33 ?> 83 34 <p><?php printf(__('Welcome to WordPress installation. We’re now going to go through a few steps to get you up and running with the latest in personal publishing platforms. You may want to peruse the <a href="%s">ReadMe documentation</a> at your leisure.'), '../readme.html'); ?></p> 84 35 <h2 class="step"><a href="install.php?step=1"><?php _e('First Step »'); ?></a></h2> 85 36 <?php 86 break; 87 37 break; 88 38 case 1: 89 90 39 ?> 91 40 <h1><?php _e('First Step'); ?></h1> … … 93 42 94 43 <form id="setup" method="post" action="install.php?step=2"> 95 <table width="100%"> 96 <tr> 97 <th width="33%"><?php _e('Weblog title:'); ?></th> 98 <td><input name="weblog_title" type="text" id="weblog_title" size="25" /></td> 99 </tr> 100 <tr> 101 <th><?php _e('Your e-mail:'); ?></th> 102 <td><input name="admin_email" type="text" id="admin_email" size="25" /></td> 103 </tr> 104 <tr> 105 <th scope="row" valign="top"> <?php __('Privacy:'); ?></th> 106 <td><label><input type="checkbox" name="blog_public" value="1" checked="checked" /> <?php _e('I would like my blog to appear in search engines like Google and Technorati.'); ?></label></td> 107 </tr> 108 </table> 109 <p><em><?php _e('Double-check that email address before continuing.'); ?></em></p> 110 <h2 class="step"> 111 <input type="submit" name="Submit" value="<?php _e('Continue to Second Step »'); ?>" /> 112 </h2> 44 <table width="100%"> 45 <tr> 46 <th width="33%"><?php _e('Weblog title:'); ?></th> 47 <td><input name="weblog_title" type="text" id="weblog_title" size="25" /></td> 48 </tr> 49 <tr> 50 <th><?php _e('Your e-mail:'); ?></th> 51 <td><input name="admin_email" type="text" id="admin_email" size="25" /></td> 52 </tr> 53 <tr> 54 <th scope="row" valign="top"> <?php __('Privacy:'); ?></th> 55 <td><label><input type="checkbox" name="blog_public" value="1" checked="checked" /> <?php _e('I would like my blog to appear in search engines like Google and Technorati.'); ?></label></td> 56 </tr> 57 </table> 58 <p><em><?php _e('Double-check that email address before continuing.'); ?></em></p> 59 <h2 class="step"><input type="submit" name="Submit" value="<?php _e('Continue to Second Step »'); ?>" /></h2> 113 60 </form> 114 61 115 62 <?php 116 break;63 break; 117 64 case 2: 118 119 // Fill in the data we gathered 120 $weblog_title = stripslashes($_POST['weblog_title']); 121 $admin_email = stripslashes($_POST['admin_email']); 122 $public = (int) $_POST['blog_public']; 123 // check e-mail address 124 if (empty($admin_email)) { 125 die (__("<strong>ERROR</strong>: please type your e-mail address")); 126 } else if (!is_email($admin_email)) { 127 die (__("<strong>ERROR</strong>: the e-mail address isn't correct")); 128 } 65 // Fill in the data we gathered 66 $weblog_title = stripslashes($_POST['weblog_title']); 67 $admin_email = stripslashes($_POST['admin_email']); 68 $public = (int) $_POST['blog_public']; 69 // check e-mail address 70 if (empty($admin_email)) { 71 die(__("<strong>ERROR</strong>: please type your e-mail address")); 72 } else if (!is_email($admin_email)) { 73 die(__("<strong>ERROR</strong>: the e-mail address isn't correct")); 74 } 129 75 130 76 ?> … … 134 80 135 81 <?php 136 137 $result = wp_install($weblog_title, __('admin'), $admin_email, $public); 138 extract($result); 82 $result = wp_install($weblog_title, __('admin'), $admin_email, $public); 83 extract($result); 139 84 ?> 140 85 … … 142 87 143 88 <p><?php printf(__('Now you can <a href="%1$s">log in</a> with the <strong>username</strong> "<code>admin</code>" and <strong>password</strong> "<code>%2$s</code>".'), '../wp-login.php', $password); ?></p> 144 <p><?php _e('<strong><em>Note that password</em></strong> carefully! It is a <em>random</em> password that was generated just for you. If you lose it, you will have to delete the tables from the database yourself, and re-install WordPress. So to review:'); ?> 145 </p> 89 <p><?php _e('<strong><em>Note that password</em></strong> carefully! It is a <em>random</em> password that was generated just for you. If you lose it, you will have to delete the tables from the database yourself, and re-install WordPress. So to review:'); ?></p> 90 146 91 <dl> 147 <dt><?php _e('Username'); ?></dt>148 <dd><code><?php _e('admin') ?></code></dd>149 <dt><?php _e('Password'); ?></dt>150 <dd><code><?php echo $password; ?></code></dd>92 <dt><?php _e('Username'); ?></dt> 93 <dd><code><?php _e('admin') ?></code></dd> 94 <dt><?php _e('Password'); ?></dt> 95 <dd><code><?php echo $password; ?></code></dd> 151 96 <dt><?php _e('Login address'); ?></dt> 152 <dd><a href="../wp-login.php">wp-login.php</a></dd>97 <dd><a href="../wp-login.php">wp-login.php</a></dd> 153 98 </dl> 154 99 <p><?php _e('Were you expecting more steps? Sorry to disappoint. All done! :)'); ?></p> 100 155 101 <?php 156 break;102 break; 157 103 } 158 104 ?> 105 159 106 <p id="footer"><?php _e('<a href="http://wordpress.org/">WordPress</a>, personal publishing platform.'); ?></p> 160 107 </body>
Note: See TracChangeset
for help on using the changeset viewer.