Siriux, making it flow

mhaft

Joined: 2008-07-23
Posts: 27
Posted: Thu, 2008-11-27 09:38

I've adapted the Siriux theme to add side columns, trouble is they cause the centre column to be pushed downward when the page size is too small. I've figured out how to edit theme.inc to remove the fixed page size code but when I do this it causes a bug that makes me unable to add modules to the gallery via the admin interface, i.e. show comments in the photo pages etc etc

Any ideas why this might be? Or, even better, how to fix it?

 
floridave
floridave's picture

Joined: 2003-12-22
Posts: 27300
Posted: Thu, 2008-11-27 14:35
Quote:
adapted the Siriux theme

would be nice to see what you are changing.

Quote:
it causes a bug that makes me unable to add modules to the gallery via the admin interface,

Short term solution:
use the matrix theme as the default theme and use your theme for the albums.

Dave

_____________________________________________
Blog & G2 || floridave - Gallery Team

 
mhaft

Joined: 2008-07-23
Posts: 27
Posted: Thu, 2008-11-27 15:11

Oops, my bad.

Theme.inc changes below, items in bold were deleted and this fixed the page width issue but it caused other bugs to appear.

/**
* @see GalleryTheme::getSettings()
*/
function getSettings($itemId=null) {
list ($ret, $settings, $params) = parent::getSettings($itemId);
if ($ret) {
return array($ret, null);
}

/* Add in our custom settings */
$settings[] = array(
'key' => 'contentWidth',
'name' => $this->translate('Width of page content in pixels'),
'type' => 'text-field',
'typeParams' => array('size' => 2),
'value' => $params['contentWidth']);

$settings[] = array(
'key' => 'groupByYear',
'name' => $this->translate(
'Group sub-albums by year (album must be sorted by date!)'),
'type' => 'checkbox',
'value' => $params['groupByYear']);
$settings[] = array(
'key' => 'enableImageMap',
'name' => $this->translate(
'Enable prev/next navigation by clicking in the left/right half of the image'),
'type' => 'checkbox',
'value' => $params['enableImageMap']);

return array(null, $settings);
}

Sadly, don't think using the matrix theme is possible at this point but might be a solution for the future (deadline to meet on Monday).

 
psygarden

Joined: 2003-03-25
Posts: 128
Posted: Sun, 2008-11-30 18:45

Search all files for reference to the "contentWidth" parameter, it's probably still referenced somewhere...

I find it in:
templates\theme.tpl
theme.inc

Also the width is saved in the database as a theme parameter, so maybe it wouldn't hurt uninstalling and reinstalling the theme after making such modifications!

Did you flush the template cache in maintenance options and the site acceleration feature?