$results = $wpdb->get_results($query);
        $active_users = $results[0]->active;
        // Blocked users
        $query = 'SELECT COUNT(state) AS blocked FROM ' . KNEWS_USERS . ' WHERE state=3';
        $results = $wpdb->get_results($query);
        $blocked_users = $results[0]->blocked;
        $total_users = $not_confirmed_users + $active_users + $blocked_users;
        ?>
		
			<h3><span><?php 
        _e('Current status of subscriptions', 'knews');
        ?>
</span></h3>
			<?php 
        if ($total_users != 0) {
            knews_drawPie(array($active_users, $not_confirmed_users, $blocked_users), array("", "", ""), 'chart1.png', 'users.txt', false, false);
            ?>
				<div class="table_float">
					<table border="0" cellpadding="0" cellspacing="0" width="350">
						<tr class="alt">
						<td><img src="<?php 
            echo KNEWS_URL;
            ?>
/images/legend_blue.gif" width="13" height="13" alt="1" /> <?php 
            _e('Active users:', 'knews');
            ?>
</td><td align="right"><?php 
            echo $active_users;
            ?>
</td><td align="right"><?php 
            echo knews_safe_percent($active_users, $total_users);
            $mobile += $results[0]->clicks;
            $e_serie9[] = $mobile;
        }
        ?>
			<h3><span><?php 
        _e('Delivery issues & user unsubscription stats for: ', 'knews');
        echo $news_name;
        ?>
</span></h3>

			<?php 
        $total_users = $enviaments_ok + $enviaments_error;
        $realment_ok = $enviaments_ok - ($hbounced + $sbounced + $blocks);
    }
    if ($total_users != 0) {
        knews_drawPie(array($realment_ok, $enviaments_error, $blocks, $sbounced, $hbounced), array("", "", "", "", ""), 'chart1.png', 'news.txt', false, false);
        ?>
			<div class="table_float">
				<table border="0" cellpadding="0" cellspacing="0" width="350">
					<tr class="alt">
						<td><img src="<?php 
        echo KNEWS_URL;
        ?>
/images/legend_blue.gif" width="13" height="13" alt="1" /></td>
						<td><?php 
        _e('Sendings OK', 'knews');
        ?>
</td><td align="right"><?php 
        echo $realment_ok;
        ?>
</td><td align="right"><?php