Reverting non-essential stuff for a mean-and-lean 2.0.7 release

git-svn-id: https://develop.svn.wordpress.org/branches/2.0@4709 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Mark Jaquith 2007-01-09 10:04:49 +00:00
parent 1b8394c1fc
commit 000bcd928e
3 changed files with 15 additions and 23 deletions

View File

@ -140,8 +140,7 @@ case 'delete':
$post_id = (isset($_GET['post'])) ? intval($_GET['post']) : intval($_POST['post_ID']);
$post = & get_post($post_id);
if ( $post->post_status == 'static')
if ( 'static' == $post->post_status )
check_admin_referer('delete-page_' . $post_id);
else
check_admin_referer('delete-post_' . $post_id);
@ -158,7 +157,7 @@ case 'delete':
}
$sendback = wp_get_referer();
if ( $post->post_status == 'static' )
if ( 'static' == $post->post_status )
$sendback = get_option('siteurl') . '/wp-admin/edit-pages.php';
elseif ( strstr($sendback, 'post.php') )
$sendback = get_option('siteurl') .'/wp-admin/post.php';

View File

@ -2228,10 +2228,7 @@ function status_header( $header ) {
elseif ( 410 == $header )
$text = 'Gone';
// if ( substr(php_sapi_name(), 0, 3) == 'cgi' )
@header("HTTP/1.1 $header $text");
// else
// @header("Status: $header $text");
@header("HTTP/1.1 $header $text");
}
function nocache_headers() {

View File

@ -71,23 +71,19 @@ if ( defined('WP_CACHE') )
define('WPINC', 'wp-includes');
require_once (ABSPATH . WPINC . '/wp-db.php');
// $table_prefix will be deprecated in version 2.1
$wpdb->prefix = $table_prefix;
if ( preg_match('|[^a-z0-9_]|i', $wpdb->prefix) )
die(__('<strong>ERROR</strong>: <code>$table_prefix</code> in <code>wp-config.php</code> can only contain numbers, letters, and underscores.'));
// Table names
$wpdb->posts = $wpdb->prefix . 'posts';
$wpdb->users = $wpdb->prefix . 'users';
$wpdb->categories = $wpdb->prefix . 'categories';
$wpdb->post2cat = $wpdb->prefix . 'post2cat';
$wpdb->comments = $wpdb->prefix . 'comments';
$wpdb->links = $wpdb->prefix . 'links';
$wpdb->linkcategories = $wpdb->prefix . 'linkcategories';
$wpdb->options = $wpdb->prefix . 'options';
$wpdb->postmeta = $wpdb->prefix . 'postmeta';
$wpdb->usermeta = $wpdb->prefix . 'usermeta';
$wpdb->posts = $table_prefix . 'posts';
$wpdb->users = $table_prefix . 'users';
$wpdb->categories = $table_prefix . 'categories';
$wpdb->post2cat = $table_prefix . 'post2cat';
$wpdb->comments = $table_prefix . 'comments';
$wpdb->links = $table_prefix . 'links';
$wpdb->linkcategories = $table_prefix . 'linkcategories';
$wpdb->options = $table_prefix . 'options';
$wpdb->postmeta = $table_prefix . 'postmeta';
$wpdb->usermeta = $table_prefix . 'usermeta';
$wpdb->prefix = $table_prefix;
if ( defined('CUSTOM_USER_TABLE') )
$wpdb->users = CUSTOM_USER_TABLE;