Pagination/404 I believe wp is getting a page ahead of itself

Using query_posts is not advised anymore and in your instance, using it outside of a page template will cause strange results, query_posts is used for altering the main loop of your site, therefore its advised to use something like WP_Query instead.

Replace from line 14 of your code:

<?php
        //bad: do not use query_posts
        global $query_string;
        query_posts("{$query_string}&posts_per_page=8");
        if ( have_posts() ) while ( have_posts() ) : the_post();
?>

With this,

<?php
        //good: use WP_query instead
        $paged = get_query_var('paged');
        $wp_query = new WP_Query(array('posts_per_page' => 8, 'paged' => $paged));
        while ($wp_query->have_posts()) : $wp_query->the_post();
?>

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)