'Why I get error code 404 and can I remove and solve this?
Hey I try to enable multi site on my Word Press Server and it's doesn't work. Every Time I tried to create new website (subdomain) I got forbidden and 404 error message.
This is the error message on the wp-admin: "Not Found
The requested URL was not found on this server.
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request."
The Error message on website visitor: "Forbidden
You don't have permission to access this resource.
Additionally, a 403 Forbidden error was encountered while trying to use an ErrorDocument to handle the request."
wp-comfig code:
<?php
/**
* The base configuration for WordPress
*
* The wp-config.php creation script uses this file during the installation.
* You don't have to use the web site, you can copy this file to "wp-config.php"
* and fill in the values.
*
* This file contains the following configurations:
*
* * Database settings
* * Secret keys
* * Database table prefix
* * ABSPATH
*
* @link https://wordpress.org/support/article/editing-wp-config-php/
*
* @package WordPress
*/
// ** Database settings - You can get this info from your web host ** //
/** The name of the database for WordPress */
define('DB_NAME', 'barelzri_WPFIA');
/** Database username */
define('DB_USER', 'barelzri_WPFIA');
/** Database password */
define('DB_PASSWORD', 'POEP![dB]RNYFvRW1');
/** Database 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', '699a493060e514887a26f82a094c12fb8e3e21f0d0a69d8a3ca2b1f1b1cf37af');
define('SECURE_AUTH_KEY', 'aad37065fb37a407d07f676eb4dd885dd1b70ad71852c68f8f37bf4083a4fe8d');
define('LOGGED_IN_KEY', '524b3460b9b74304d633d0fdca1da1d9a3879d8dd1d1d5f3ba52e8cb9dd95bb2');
define('NONCE_KEY', '89b39d5a1f1aaabd4036074fd4ba3e75988198eda913938de7aab03ac5ff20bb');
define('AUTH_SALT', '2c8401cdfb341a3d25d38df2eeed503946a759496a6810f63870cd3bced53b49');
define('SECURE_AUTH_SALT', '1e7c986ecba80d02c5e774cf16cd890137d1626aa389593da114b479ef9fb0f9');
define('LOGGED_IN_SALT', 'da8e8f83f4fa981cfa13428896ce90cbc683dd3d314df760a9cea1dd2e1e0184');
define('NONCE_SALT', 'e27d7005c5b1d68424d085d444327dc304e64cd3ba317bb0e45d641f4f425632');
/**#@-*/
/**
* 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 = 'ZjI_';
define('WP_CRON_LOCK_TIMEOUT', 120);
define('AUTOSAVE_INTERVAL', 300);
define('WP_POST_REVISIONS', 5);
define('EMPTY_TRASH_DAYS', 7);
define('WP_AUTO_UPDATE_CORE', true);
define( 'WP_ALLOW_MULTISITE', true );
define( 'MULTISITE', true );
define( 'SUBDOMAIN_INSTALL', true );
define( 'DOMAIN_CURRENT_SITE', 'barelzrihan.com' );
define( 'PATH_CURRENT_SITE', '/' );
define( 'SITE_ID_CURRENT_SITE', 1 );
define( 'BLOG_ID_CURRENT_SITE', 1 );
/* Add any custom values between this line and the "stop editing" line. */
/* That's all, stop editing! Happy publishing. */
/** Sets up WordPress vars and included files. */
require_once ABSPATH . 'wp-settings.php';
.htaccess code:
RewriteEngine On
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
RewriteBase /
RewriteRule ^index\.php$ - [L]
# add a trailing slash to /wp-admin
RewriteRule ^wp-admin$ wp-admin/ [R=301,L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^(wp-(content|admin|includes).*) $1 [L]
RewriteRule ^(.*\.php)$ $1 [L]
RewriteRule . index.php [L]
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
