diff options
| author | Max Kremmel <xing@synapse.plus.com> | 2006-02-09 10:30:37 +0000 |
|---|---|---|
| committer | Max Kremmel <xing@synapse.plus.com> | 2006-02-09 10:30:37 +0000 |
| commit | 252d2ff950016d1623392bc4ea39b2e55bfe70c0 (patch) | |
| tree | 16fba91e625fae6b53961d01975c148ba4ba42f5 /list_content.php | |
| parent | f79a5cdd8905832db9d8eb18a7605bcb61ac3940 (diff) | |
| download | liberty-252d2ff950016d1623392bc4ea39b2e55bfe70c0.tar.gz liberty-252d2ff950016d1623392bc4ea39b2e55bfe70c0.tar.bz2 liberty-252d2ff950016d1623392bc4ea39b2e55bfe70c0.zip | |
remove getPref() and we continue using old method getPreference();
replace all direct accesses with getPreference() or setPreference() (new function)
BitSystem::getPreference() and related functions will be renamed to BitSystem::getConfig()
Diffstat (limited to 'list_content.php')
| -rw-r--r-- | list_content.php | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/list_content.php b/list_content.php index 0a454e2..028c94a 100644 --- a/list_content.php +++ b/list_content.php @@ -3,7 +3,7 @@ * list_content * * @author spider <spider@steelsun.com> - * @version $Revision: 1.10 $ + * @version $Revision: 1.11 $ * @package liberty * @subpackage functions */ @@ -19,17 +19,17 @@ if( !empty( $_REQUEST['sort_mode'] ) ) { $gBitSmarty->assign( 'sort_mode', $content_sort_mode ); } -$max_content = $gBitSystem->mPrefs['max_records']; +$max_content = $gBitSystem->getPreference( 'max_records' ); $offset_content = @BitBase::verifyId( $_REQUEST['offset'] ) ? $_REQUEST['offset'] : 0; $gBitSmarty->assign( 'user_id', @BitBase::verifyId( $_REQUEST['user_id'] ) ? $_REQUEST['user_id'] : NULL ); $gBitSmarty->assign( 'curPage', $page = @BitBase::verifyId( $_REQUEST['page'] ) ? $_REQUEST['page'] : 1 ); -$offset_content = ( $page - 1 ) * $gBitSystem->mPrefs['max_records']; +$offset_content = ( $page - 1 ) * $gBitSystem->getPreference( 'max_records' ); // now that we have all the offsets, we can get the content list include_once( LIBERTY_PKG_PATH.'get_content_list_inc.php' ); // calculate page number -$numPages = ceil( $contentList['cant'] / $gBitSystem->mPrefs['max_records'] ); +$numPages = ceil( $contentList['cant'] / $gBitSystem->getPreference( 'max_records' ) ); $gBitSmarty->assign( 'numPages', $numPages ); //$gBitSmarty->assign_by_ref('offset', $offset); |
