[ Index ]
 

Code source de WordPress 2.1.2

Accédez au Source d'autres logiciels libresSoutenez Angelica Josefina !

title

Body

[fermer]

/wp-admin/ -> upgrade.php (source)

   1  <?php
   2  define('WP_INSTALLING', true);
   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://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  
   6  require('../wp-config.php');
   7  timer_start();
   8  require_once (ABSPATH . '/wp-admin/upgrade-functions.php');
   9  
  10  if (isset($_GET['step']))
  11      $step = $_GET['step'];
  12  else
  13      $step = 0;
  14  @header('Content-type: ' . get_option('html_type') . '; charset=' . get_option('blog_charset'));
  15  ?>
  16  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  17  <html xmlns="http://www.w3.org/1999/xhtml" <?php language_attributes(); ?>>
  18  <head>
  19      <meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php echo get_option('blog_charset'); ?>" />
  20      <title><?php _e('WordPress &rsaquo; Upgrade'); ?></title>
  21      <link rel="stylesheet" href="<?php echo get_option('siteurl') ?>/wp-admin/install.css?version=<?php bloginfo('version'); ?>" type="text/css" />
  22      <?php if ( ('rtl' == $wp_locale->text_direction) ) : ?>
  23      <link rel="stylesheet" href="<?php echo get_option('siteurl') ?>/wp-admin/install-rtl.css?version=<?php bloginfo('version'); ?>" type="text/css" />
  24      <?php endif; ?>
  25  </head>
  26  <body>
  27  <h1 id="logo"><img alt="WordPress" src="images/wordpress-logo.png" /></h1>
  28  <?php
  29  switch($step) {
  30      case 0:
  31          $goback = attribute_escape(stripslashes(wp_get_referer()));
  32  ?> 
  33  <p><?php _e('This file upgrades you from any previous version of WordPress to the latest. It may take a while though, so be patient.'); ?></p> 
  34  <h2 class="step"><a href="upgrade.php?step=1&amp;backto=<?php echo $goback; ?>"><?php _e('Upgrade WordPress &raquo;'); ?></a></h2>
  35  <?php
  36          break;
  37      case 1:
  38          wp_upgrade();
  39  
  40          if ( empty( $_GET['backto'] ) )
  41              $backto = __get_option('home');
  42          else
  43              $backto = attribute_escape(stripslashes($_GET['backto']));
  44  ?> 
  45  <h2><?php _e('Step 1'); ?></h2> 
  46      <p><?php printf(__("There's actually only one step. So if you see this, you're done. <a href='%s'>Have fun</a>!"),  $backto); ?></p>
  47  
  48  <!--
  49  <pre>
  50  <?php printf(__('%s queries'), $wpdb->num_queries); ?>
  51  
  52  <?php printf(__('%s seconds'), timer_stop(0)); ?>
  53  </pre>
  54  -->
  55  
  56  <?php
  57          break;
  58  }
  59  ?>
  60  </body>
  61  </html>


Généré le : Fri Mar 30 19:41:27 2007 par Balluche grâce à PHPXref 0.7