• What triggers the WP installation process?

    I have a client who just accidentally reinstalled WordPress over her active WordPress website – completely trashed the database. For some reason, she was prompted to “create a login” which was actually the WP installation dialog. And that wiped out the database.

    Any idea what could cause that? Any ideas how to prevent that?

    Thanks for the help,

    Josh

Viewing 3 replies - 1 through 3 (of 3 total)
  • Some things can just get corrupted – WordPress looks for a few triggers which identifies and incomplete install. It’s happened once or twice to me and the only solution I could come up with was to re-install from scratch.

    To avoid it happening again in the future, you can add this to your .htaccess to block access to the file:

    	<files install.php>
    		<IfModule mod_authz_core.c>
    			Require all denied
    		</IfModule>
    		<IfModule !mod_authz_core.c>
    			Order allow,deny
    			Deny from all
    		</IfModule>
    	</files>
    Thread Starter Josh Robbs

    (@jwrobbs)

    Thanks for the help, Shannon. I’m no .htaccess guru but could you create a redirect? Instead of denying access, could you send them to the home page or an error page for instance?

    Thanks for the help,

    Josh

    Yes, you could do something like:

    
    RewriteEngine On
    RedirectMatch 301 ^/path_to_file/install.php$ /
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘WordPress randomly(?) tries to reinstall itself’ is closed to new replies.