簡體   English   中英

WordPress 500-內部服務器錯誤(編輯)

[英]Wordpress 500 - Internal server error (edit)

我收到“ 500-內部服務器錯誤”。 在我的WordPress網站的域上。

通過IIS(Win7)中的Web平台安裝程序在本地安裝WordPress。

在Firefox本地開發了一個登錄頁面,然后將該站點通過FTP傳輸到Web服務器(該Web服務器還托管來自各個域的多個站點)。

使用MySQL Workbench 5.2 CE創建和導出數據庫,該數據庫也已上載到服務器。 數據庫已測試。

我已經閱讀了與“ Wordpress”和“ 500-內部服務器錯誤。”有關的所有帖子,但沒有任何幫助。

我嘗試創建包含以下內容的.htaccess文件:

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

# END WordPress

IIS中的所有文件路徑均正確。

以下是wp-config.php文件

<?php
/**
 * The base configurations of the WordPress.
  *
  * This file has the following configurations: MySQL settings, Table Prefix,
  * Secret Keys, WordPress Language, and ABSPATH. You can find more information
  * by visiting {@link http://codex.wordpress.org/Editing_wp-config.php Editing
  * wp-config.php} Codex page. You can get the MySQL settings from your web host.
  *
  * This file is used by the wp-config.php creation script during the
  * installation. You don't have to use the web site, you can just copy this file
  * to "wp-config.php" and fill in the values.
  *
  * @package WordPress
  */

 // ** MySQL settings - You can get this info from your web host ** //
 /** The name of the database for WordPress */
 define('DB_NAME', 'zxcvb');

 /** MySQL database username */
 define('DB_USER', 'zxcvb');

 /** MySQL database password */
 define('DB_PASSWORD', 'zxcvb');

 /** MySQL hostname */
 define('DB_HOST', 'localhost');

 /** Database Charset to use in creating database tables. */
 define('DB_CHARSET', 'utf8');

 /** The Database Collate type. Don't change this if in doubt. */
 define('DB_COLLATE', '');


 /**#@+
  * Authentication Unique Keys and Salts.
  *
  * Change these to different unique phrases!
  * You can generate these using the {@link https://api.wordpress.org/secret-key/1.1     /salt/ WordPress.org secret-key service}
  * You can change these at any point in time to invalidate all existing cookies. This      will force all users to have to log in again.
  *
  * @since 2.6.0
  */
 define('AUTH_KEY',         'put your unique phrase here');
 define('SECURE_AUTH_KEY',  'put your unique phrase here');
 define('LOGGED_IN_KEY',    'put your unique phrase here');
 define('NONCE_KEY',        'put your unique phrase here');
 define('AUTH_SALT',        'put your unique phrase here');
 define('SECURE_AUTH_SALT', 'put your unique phrase here');
 define('LOGGED_IN_SALT',   'put your unique phrase here');
 define('NONCE_SALT',       'put your unique phrase here');

 /**#@-*/

 /**
  * WordPress Database Table prefix.
  *
  * You can have multiple installations in one database if you give each a unique
  * prefix. Only numbers, letters, and underscores please!
  */
 $table_prefix  = 'wp_';

 /**
  * WordPress Localized Language, defaults to English.
  *
  * Change this to localize WordPress. A corresponding MO file for the chosen
  * language must be installed to wp-content/languages. For example, install
  * de_DE.mo to wp-content/languages and set WPLANG to 'de_DE' to enable German
  * language support.
  */
 define('WPLANG', '');

 /**
  * For developers: WordPress debugging mode.
  *
  * Change this to true to enable the display of notices during development.
 * It is strongly recommended that plugin and theme developers use WP_DEBUG
 * in their development environments.
 */
define('WP_DEBUG', false);

/* That's all, stop editing! Happy blogging. */

/** Absolute path to the WordPress directory. */
if ( !defined('ABSPATH') )
    define('ABSPATH', dirname(__FILE__) . '/');

/** Sets up WordPress vars and included files. */
require_once(ABSPATH . 'wp-settings.php');

請幫忙! 謝謝

WordPress將一些特定於域的設置存儲在其選項表中。 如果您在本地進行安裝,然后將其導出到外部托管服務提供商,則很有可能在WordPress數據庫和本地安裝設置中仍未正確配置這些設置。

檢查WordPress中的options表(根據需要添加前綴)。 在行中查找那些引用到本地安裝(其URL或資源)的選項,並使用適合您主機的相應值更新它們。

特別是,我建議您使用以下option_name檢查行:

  • 網站網址

正確設置這些文件后,您應該可以從其管理界面訪問WP的安裝並修復其他文件(例如圖像URL和類似的其他東西)。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM