Included Sales Pricing, Purchasing Prising, Cost update and Reorder Levels in tabs...
[fa-stable.git] / includes / db_pager.inc
index 64a79eda8e633cd4316147599bc1be0062fa0346..36afb923543c739e7c5b159f070c29ae45093b65 100644 (file)
@@ -283,7 +283,9 @@ class db_pager {
            }
                                
            if (count($ord)) {
-                       $sql .= " ORDER BY " . implode($ord, ',');
+                       $ord = array_map(function_exists('mysql_real_escape_string') ? 
+                               'mysql_real_escape_string': 'mysql_escape_string', $ord);
+                       $sql .= " ORDER BY " . implode(',', $ord);
                } else {
                        if($order)
                                $sql .= " ORDER BY $order"; // original base query order