diff options
| author | Meik Sievertsen <acydburn@phpbb.com> | 2007-01-17 18:41:49 +0000 |
|---|---|---|
| committer | Meik Sievertsen <acydburn@phpbb.com> | 2007-01-17 18:41:49 +0000 |
| commit | a841fe70a8234bf158165105339e32aa5ceb75a2 (patch) | |
| tree | a3e85eb75ec6bb59b331bd830667532d4511a868 /phpBB/includes/db/dbal.php | |
| parent | 708113b790368fffbf57eb5b96c8132eda00ba9c (diff) | |
| download | forums-a841fe70a8234bf158165105339e32aa5ceb75a2.tar forums-a841fe70a8234bf158165105339e32aa5ceb75a2.tar.gz forums-a841fe70a8234bf158165105339e32aa5ceb75a2.tar.bz2 forums-a841fe70a8234bf158165105339e32aa5ceb75a2.tar.xz forums-a841fe70a8234bf158165105339e32aa5ceb75a2.zip | |
ok, handled some bugs... the most important being validate_username (the variable passed to validate_data([...]array('username', [...])) and updating group listings while doing relevant group actions. Oh, and PM icons are working now. :o
git-svn-id: file:///svn/phpbb/trunk@6894 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/db/dbal.php')
| -rw-r--r-- | phpBB/includes/db/dbal.php | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/phpBB/includes/db/dbal.php b/phpBB/includes/db/dbal.php index 1f48909d43..df6e453329 100644 --- a/phpBB/includes/db/dbal.php +++ b/phpBB/includes/db/dbal.php @@ -115,6 +115,24 @@ class dbal } /** + * Build LIMIT query + * Doing some validation here. + */ + function sql_query_limit($query, $total, $offset = 0, $cache_ttl = 0) + { + if (empty($query)) + { + return false; + } + + // Never use a negative total or offset + $total = ($total < 0) ? 0 : $total; + $offset = ($offset < 0) ? 0 : $offset; + + return $this->_sql_query_limit($query, $total, $offset, $cache_ttl); + } + + /** * Fetch all rows */ function sql_fetchrowset($query_id = false) |
