contact us pagination
This commit is contained in:
@@ -522,7 +522,7 @@ class Bkouser extends Bko_Controller {
|
||||
$page = is_numeric($page) ? $page : 0;
|
||||
$extra_qr = '';
|
||||
|
||||
var_dump($_POST);
|
||||
// var_dump($_POST);
|
||||
|
||||
if ($_POST) {
|
||||
|
||||
@@ -578,13 +578,25 @@ class Bkouser extends Bko_Controller {
|
||||
$data = array();
|
||||
$data['page_title'] = 'Site Contacts';
|
||||
|
||||
$page = ($this->uri->segment(3)) ? $this->uri->segment(3) : 0;
|
||||
$page = is_numeric($page) ? $page : 0;
|
||||
|
||||
$config = $this->PrepPagination(10, 3, '/bkouser/contact');
|
||||
|
||||
$mysql0 = "SELECT * FROM contacts";
|
||||
$q = $this->db->query($mysql0);
|
||||
$config["total_rows"] = $q->num_rows();
|
||||
|
||||
$this->load->library('pagination');
|
||||
$this->pagination->initialize($config);
|
||||
$data["pagination_links"] = $this->pagination->create_links();
|
||||
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SElECT added::date||'<br>'||loc||'<br>'||(CASE WHEN last_login::date IS NULL THEN ' ' ELSE last_login::date::text END) AS Act,"
|
||||
. " username||'<br>'||firstname||' '||lastname AS Name, "
|
||||
. " '<div id=\"sdd'||id||'\"><button id=\"sel'||id||'\" class=\"btn btn-warning btn-xs\" onclick=\"return selectMember('''||id||''');\" >Select['||id||']</button></div>' AS select "
|
||||
. " FROM members ORDER BY id DESC LIMIT 100";
|
||||
$mysql = " SELECT created||'<br>'||email||'<br>'||member_id||'<div id=\"sdd'||id||'\"><button id=\"sel'||id||'\" class=\"btn btn-warning btn-xs\" onclick=\"return selectMessage('''||id||''');\" >Select['||id||']</button></div>' AS sender,your_message FROM contacts ORDER BY id desc";
|
||||
|
||||
$mysql = " SELECT your_message ||'<hr> Added:'|| created::date||' - From:'||email||' ID-'||member_id AS site_msg , '<div id=\"sdd'||id||'\"><button id=\"sel'||id||'\" class=\"btn btn-warning btn-xs\" onclick=\"return selectMessage('''||id||''');\" >Select['||id||']</button></div>' AS acti
|
||||
FROM contacts ORDER BY id DESC LIMIT " . $config["per_page"] . " OFFSET " . $page; ;
|
||||
$query = $this->db->query($mysql);
|
||||
// $this->table->set_heading('Account', 'Created', 'Action');
|
||||
|
||||
|
||||
@@ -23,6 +23,13 @@
|
||||
</div>
|
||||
|
||||
|
||||
<div class="panel panel-flat">
|
||||
<div class="panel-heading">
|
||||
<?=$pagination_links ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
<!-- /traffic sources -->
|
||||
|
||||
|
||||
Reference in New Issue
Block a user