Wordpress - Admin not found -


have strange error has popped struggling resolve.

i have wordpress install using sub domain method:

www.example.com/wordpress

in root directory have .htaccess:

# begin wordpress <ifmodule mod_rewrite.c> rewriteengine on rewritebase / rewriterule ^index\.php$ - [l] rewritecond %{request_filename} !-f rewritecond %{request_filename} !-d rewriterule . /index.php [l] </ifmodule> # end wordpress 

and index file:

<?php define('wp_use_themes', true);  /** loads wordpress environment , template */ require( dirname( __file__ ) . '/wordpress/wp-blog-header.php' ); 

home set to: www.example.com url set to: www.example.com/wordpress

when try , access admin at: www.example.com/wordpress/wp-admin error: sorry, page looking not found.

this not new install of wordpress , issue happened after auto update.

how go bug testing this?

you're using subdirectory installation (rather subdomain installation); such, .htaccess file doesn't belong in root directory - should in /wordpress/ directory, along rest of installation.

in addition, .htaccess needs edited account fact resides in subdirectory:

# begin wordpress <ifmodule mod_rewrite.c> rewriteengine on rewritebase /wordpress/ rewriterule ^index\.php$ - [l] rewritecond %{request_filename} !-f rewritecond %{request_filename} !-d rewriterule . /wordpress/index.php [l] </ifmodule> # end wordpress 

you should remove wordpress/ part index.php file. php magic constant __file__ means 'relative file', if index.php file in /wordpress/, it's saying 'look in /wordpress/wordpress/ wp-blog-header.php`.

so amend line in index.php file this:

require( dirname( __file__ ) . '/wp-blog-header.php' ); 

...and should work expected.


Comments

Popular posts from this blog

python - Healpy: From Data to Healpix map -

c - Bitwise operation with (signed) enum value -

xslt - Unnest parent nodes by child node -