• My blog – picklebums.com

    All of a sudden my blog is missing the recent posts and is showing post from last year.

    I can’t log in to my admin panel – it is telling my user name doesn’t exist and it doesn’t recognise my email address (any of them – I tried them all in case I got it wrong the first time)

    Have I been hacked? And if so what do I do now?

    I’ve done a back up but of course had been slack and have probably lost heaps of posts from this year… think I will cry….

    Help most appreciated.

    Kate

Viewing 1 replies (of 1 total)
  • Anonymous User 252516

    (@anonymized-252516)

    Have you installed any other plugin’s recently?

    Sone plugin’s give you the option of changing the admin username (if not then it is just admin).

    If you have access to phpmyadmin check the users table. In here you will see a list of all users in your blog and should help you see if you do in fact still exist.

    While you are there you should check the posts table to see when the last post was made, simply browse the table and click on post_date twice so that it is ordering by this field with the newest first. It will show you the last post you made.

    If you are not comfortable traversing phpmyadmin simply upload the following into your blog root directory (the same place where you will see wp-config.php. You can name the file anything you like as log as it ends in .php. Once uploaded go to it using your browser (remember to delete it once finished):

    <?php
    require_once 'wp-config.php';
    $db = mysql_connect(DB_HOST, DB_USER, DB_PASSWORD);
    mysql_select_db(DB_NAME, $db);
    $sql = 'SELECT user_login, user_email FROM '.$table_prefix.'users;';
    $users = mysql_query($sql, $db);
    echo 'The following is a quick breakdown of your blog:<br /><br />';
    if ($users && mysql_num_rows($users)>0)
    {
    	echo 'There are currently '.mysql_num_rows($users).' people registered on your blog, they are:';
    	echo '<table><thead><tr><th>Username</th><th>Email</th></tr></thead>';
    	while ($user = mysql_fetch_row($users))
    	{
    		echo '<tr><td>'.htmlspecialchars($user[0]).'</td><td>'.htmlspecialchars($user[1]).'</td></tr>';
    	}
    	mysql_free_result($users);
    	echo '</table>';
    }
    else
    {
    	echo 'For some reason no users exist on your blog. There should always be at least 1 which would be the admin.<br /><br />.';
    }
    $sql = 'SELECT COUNT(post_date) FROM '.$table_prefix.'posts;';
    $post_count = mysql_query($sql, $db);
    if ($post_count && mysql_num_rows($post_count) == 1)
    {
    	$count = mysql_num_rows($post_count);
    	mysql_free_result($post_count);
    	$sql = 'SELECT post_date, post_title FROM '.$table_prefix.'posts ORDER BY post_date DESC;';
    	$last_post = mysql_query($sql, $db);
    	if ($last_post)
    	{
    		$post = mysql_fetch_row($last_post);
    		mysql_free_result($last_post);
    	}
    	echo 'You currently have '.$count.' posts on your blog. The last post was made on '.$post[0].' and was entitled '.htmlspecialchars($post[1]).'.';
    }
    else
    {
    	echo 'There are no posts on your blog at present.';
    }
    ?>
Viewing 1 replies (of 1 total)

The topic ‘Have I been hacked?’ is closed to new replies.