diff options
| author | Christian Fowler <spider@viovio.com> | 2006-09-06 04:51:15 +0000 |
|---|---|---|
| committer | Christian Fowler <spider@viovio.com> | 2006-09-06 04:51:15 +0000 |
| commit | e8ceef979b04a60cd9fa6cb12cef10373a8fb68d (patch) | |
| tree | c64951372573b6f29f5ddbe02f6296611e57fbaa /edit.php | |
| parent | d075bcd48256d8e48798de030ffdf896e76b8b6e (diff) | |
| download | fisheye-e8ceef979b04a60cd9fa6cb12cef10373a8fb68d.tar.gz fisheye-e8ceef979b04a60cd9fa6cb12cef10373a8fb68d.tar.bz2 fisheye-e8ceef979b04a60cd9fa6cb12cef10373a8fb68d.zip | |
add image position fractional ordering to image galleries, and user selectable per gallery layout style (matrix, auto-flow, or image position)
Diffstat (limited to 'edit.php')
| -rw-r--r-- | edit.php | 14 |
1 files changed, 13 insertions, 1 deletions
@@ -1,6 +1,6 @@ <?php /** - * @version $Header: /cvsroot/bitweaver/_bit_fisheye/edit.php,v 1.14 2006/08/29 14:48:02 squareing Exp $ + * @version $Header: /cvsroot/bitweaver/_bit_fisheye/edit.php,v 1.15 2006/09/06 04:51:15 spiderr Exp $ * @package fisheye * @subpackage functions */ @@ -35,10 +35,19 @@ if( $gBitUser->hasPermission( 'p_fisheye_change_thumb_size' ) ) { $gBitSmarty->assign( 'thumbnailSizes', $thumbnailSizes ); } +$gBitSmarty->assign( 'galleryPaginationTypes', array( FISHEYE_PAGINATION_FIXED_GRID => 'Fixed Grid', FISHEYE_PAGINATION_AUTO_FLOW => 'Auto-Flow Images', FISHEYE_PAGINATION_POSITION_NUMBER => 'Image Order Page Number' ) ); + if( !empty( $_REQUEST['savegallery'] ) ) { + + if( $_REQUEST['gallery_pagination'] == 'auto_flow' ) { + $_REQUEST['rows_per_page'] = $_REQUEST['total_per_page']; + $_REQUEST['cols_per_page'] = '1'; + } + if( $gContent->store( $_REQUEST ) ) { $gContent->storePreference( 'is_public', !empty( $_REQUEST['is_public'] ) ? $_REQUEST['is_public'] : NULL ); $gContent->storePreference( 'allow_comments', !empty( $_REQUEST['allow_comments'] ) ? $_REQUEST['allow_comments'] : NULL ); + $gContent->storePreference( 'gallery_pagination', !empty( $_REQUEST['gallery_pagination'] ) ? $_REQUEST['gallery_pagination'] : NULL ); // make sure var is fully stuffed with current data $gContent->load(); // set the mappings, or if nothing checked, nuke them all @@ -83,6 +92,9 @@ if( !empty( $_REQUEST['savegallery'] ) ) { $errors = (!empty($gContent->mErrors) ? $gContent->mErrors : array()); $gBitSmarty->assign_by_ref('errors', $errors); +$gBitSystem->setOnloadScript( 'updateGalleryPagination();' ); +$gBitSmarty->assign( 'loadAjax', TRUE ); + $gallery = $gContent->getParentGalleries(); $gBitSmarty->assign_by_ref( 'parentGalleries', $gallery ); $getHash = array( 'user_id' => $gBitUser->mUserId, 'contain_item' => $gContent->mContentId, 'max_records' => -1, 'no_thumbnails' => TRUE, 'sort_mode'=>'title_asc' ); |
