function counterize_options_display_sendreportnow_callback()
{
    echo "<input id='counterize_setting_sendreportnow' name='counterize_options[sendreportnow]' type='checkbox' value='wantsendreportnow' />";
    if (isset($_SESSION['counterize_report_status'])) {
        if ($_SESSION['counterize_report_status'] == 'sent') {
            counterize_updateText(__('Report sent!', COUNTERIZE_TD));
            unset($_SESSION['counterize_report_status']);
        } elseif ($_SESSION['counterize_report_status'] == 'error') {
            counterize_updateText(__('Error. The report could not be sent! Possible causes:
			<ol>
				<li>Create the email address wordpress@yoursite.com</li>
				<li>Settings SMTP and smtp_port need to be set in your php.ini</li>
				<li>Either set the sendmail_from setting in php.ini</li>
			</ol>', COUNTERIZE_TD));
            unset($_SESSION['counterize_report_status']);
        }
    }
}
function counterize_display_dashboard_history_page_callback()
{
    // Amount to pass as option to the graphs...
    $amount2 = counterize_get_option('amount2');
    if ($amount2 == '' || $amount2 == ' ' || !is_numeric($amount2)) {
        $amount2 = 10;
    }
    echo '
	<div id="icon-plugins" class="icon32"></div>
	<h1>' . __('Counterize', COUNTERIZE_TD) . ' - ' . __('Dashboard', COUNTERIZE_TD) . ' - ' . __('History', COUNTERIZE_TD) . '</h1>
	';
    if (current_user_can('manage_options')) {
        $updateText = '';
        if (isset($_GET['killmass']) && check_admin_referer('action_killmass')) {
            if ($_GET['killmass'] == 'yes') {
                if (isset($_POST['counterize_killemall'])) {
                    foreach ($_POST['counterize_killemall'] as $key => $val) {
                        $val = intval($val);
                        counterize_killEntry($val);
                        $updateText .= __('Entry: ' . $val . ' removed<br />', COUNTERIZE_TD);
                    }
                    counterize_updateText($updateText);
                    unset($updateText);
                }
            }
        }
        // For the zap-an-entry-option
        if (isset($_GET['kill']) && check_admin_referer('action_uri_kill')) {
            $val = intval($_GET['kill']);
            counterize_killEntry($val);
            counterize_updateText(__('Deleting entry ', COUNTERIZE_TD) . $val);
        }
        //Show latest entries
        counterize_show_history('counterize_dashboard_history', true);
    }
    //Print the footer
    counterize_pagefooter();
}