5k Limit as well for old queries

This commit is contained in:
int2001
2025-06-08 07:50:16 +00:00
parent a0113df21b
commit e79a0eaf60

View File

@@ -119,6 +119,9 @@ class Search extends CI_Controller {
$sql = $sql[0]->query;
if (stristr($sql, 'select') && !stristr($sql, 'delete') && !stristr($sql, 'update')) {
if (!(strpos(strtolower($sql),'limit'))) {
$sql.=' limit 5000';
}
$data['results'] = $this->db->query($sql);
$this->load->view('search/search_result_ajax', $data);