Index.php file broken
-
I had my site hacked where they screwed my index.php file. I was told to re-load the MYSQL database and re-load it and that should re-create the index.php file….it does not. When you try to bring the site up I get garbage on the screen…please see link
http://www.militarycommcenter.comAny help would be appreciated.
Thanks
Gary
-
It’s a prefix, not the whole table name.
If the table is
w-poststhen the prefix isw-Let me work on this and I’ll be back…thanks
You’re welcome!
Like I said, access your database via phpMyAdmin through your hosting providers control panel, and look for the “posts” table with all of your posts in it.
The comment above is where I’m getting confused….I know easy to do. ha
If the database on the server has the line W_POSTS showing a count of 9.4 due to hardly any posts where would I see the difference when viewing the config file to make sure it is pointing to the correct database. I only have one database on this server so I’m not sure how I can have the config file pointing to the wrong location.
In your wp-config.php file, look for this line:
$table_prefix = 'wp_'; // Only numbers, letters, and underscores please!Change it to:
$table_prefix = 'w_'; // Only numbers, letters, and underscores please!After making the change and looking at the url I get this:
And I thought being in the Marines was tuff……man ha
You need to set wp-config.php to access the database and us the same prefix as the existing database, or it won’t find it and will simply ask you to install again.
Also, your
/wp-admin/directory is missing most of its files, which suggests that you still haven’t uploaded all of the WordPress files.If you’re having trouble with this, it might be time to consider hiring someone so that you can give them access to your site so they can correct it quickly for you.
Please try one of the following sites:
I changed it back to WP_ and I get the site back…..
No problem Mac I know this has been a pain..thanks for all your help getting me to this point. I at least have an idea where and what to do now.
Appreciate all the hard work.
Gary
Did the site only ever have the “HELLO WORLD!” post, or were there more posts?
Also, you’re still missing a ton of files from
/wp-admin/Hey Mac,
No it didn’t, the site is a multi serive (Army, Navy etc) communication center that was running until the hack job someone did. I have my own header, forums set up for each branch of service and more.
It was/is a nice site so I won’t be giving up on getting her running. I’m double checking the files and directory content and matching it up to what I have locally from my last backup, and reviewing your comments.
Thanks again Mac for all that you’ve tried to do, it’s hard trying to be someone else’s hands and eyes through the screen.
Ok, if you aren’t seeing on the site what was in the database (like the posts that should be there), wp-config.php is not yet configured to correct to the proper database and table prefix.
I’m happy to help, but I feel like the two of us are just repeating each other at the moment, so I strongly suggest hiring someone to just take a look at this. Someone hands-on should have you back up and running before too long.
If you choose to do that, please try one of the following sites:
I’ll work on it a bit more then consider your advice..thanks
You’re welcome!
The topic ‘Index.php file broken’ is closed to new replies.