diff --git a/app/messages/messages_log.php b/app/messages/messages_log.php index 576c2776bd..8808e6e407 100644 --- a/app/messages/messages_log.php +++ b/app/messages/messages_log.php @@ -17,7 +17,7 @@ The Initial Developer of the Original Code is Mark J Crane - Portions created by the Initial Developer are Copyright (C) 2016-2018 + Portions created by the Initial Developer are Copyright (C) 2016-2019 the Initial Developer. All Rights Reserved. Contributor(s): @@ -112,10 +112,12 @@ if ($_GET['show'] == "all" && permission_exists('message_all')) { $param .= "&show=all"; } - $page = $_GET['page']; - if (strlen($page) == 0) { $page = 0; $_GET['page'] = 0; } - list($paging_controls, $rows_per_page, $var3) = paging($num_rows, $param, $rows_per_page); - $offset = $rows_per_page * $page; + if (isset($_GET['page'])) { + $page = $_GET['page']; + if (strlen($page) == 0) { $page = 0; $_GET['page'] = 0; } + list($paging_controls, $rows_per_page, $var3) = paging($num_rows, $param, $rows_per_page); + $offset = $rows_per_page * $page; + } //get the list $sql = str_replace('count(*)', '*', $sql);