diff --git a/htdocs/application/models/pastes.php b/htdocs/application/models/pastes.php index 1c25f2d..cf3990c 100755 --- a/htdocs/application/models/pastes.php +++ b/htdocs/application/models/pastes.php @@ -411,6 +411,8 @@ class Pastes extends CI_Model $n++; } } + + //pagination $config['base_url'] = site_url($root); $config['total_rows'] = $this->countPastes($ip_address); $config['per_page'] = $amount; @@ -420,6 +422,14 @@ class Pastes extends CI_Model $config['uri_segment'] = $seg; $this->pagination->initialize($config); $data['pages'] = $this->pagination->create_links(); + + //total spam attempts + $this->db->select('SUM(spam_attempts) as sum'); + $query = $this->db->get('blocked_ips'); + $q = $query->result_array(); + $data['total_spam_attempts'] = $q[0]['sum']; + + //return return $data; } diff --git a/htdocs/application/views/list_blocked_ips.php b/htdocs/application/views/list_blocked_ips.php index 16ea9c2..30adf33 100755 --- a/htdocs/application/views/list_blocked_ips.php +++ b/htdocs/application/views/list_blocked_ips.php @@ -1,5 +1,5 @@ load->view('defaults/header');?> -
51 spam-pastes eaten so far. View blocked IPs.
+spam-pastes eaten so far. View blocked IPs.