<?php
/*
+--------------------------------------------------------------------+
- | CiviCRM version 4.3 |
+ | CiviCRM version 4.4 |
+--------------------------------------------------------------------+
| Copyright CiviCRM LLC (c) 2004-2013 |
+--------------------------------------------------------------------+
function addSortOffset(&$sql, $offset, $rowcount, $sort) {
if (!empty($sort)) {
if (is_string($sort)) {
+ $sort = CRM_Utils_Type::escape($sort, 'String');
$sql .= " ORDER BY $sort ";
}
else {
}
if ($rowcount > 0 && $offset >= 0) {
+ $offset = CRM_Utils_Type::escape($offset, 'Int');
+ $rowcount = CRM_Utils_Type::escape($rowcount, 'Int');
+
$sql .= " LIMIT $offset, $rowcount ";
}
}
function getQueryObj() {
return NULL;
}
-}
\ No newline at end of file
+}