summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorZach Copley <zach@controlyourself.ca>2009-06-24 00:43:48 -0700
committerZach Copley <zach@controlyourself.ca>2009-06-24 00:43:48 -0700
commitd72a90161b1cb748b58454e4c885b1d789ef3eca (patch)
tree6090adfdd14f05e75f0e59ba99d15a195d180b99 /lib
parentb702461f6942017d1ae4a08c6701998db14ce536 (diff)
Only show "tile background" setting once an img has been uploaded
Diffstat (limited to 'lib')
-rw-r--r--lib/designsettings.php16
1 files changed, 10 insertions, 6 deletions
diff --git a/lib/designsettings.php b/lib/designsettings.php
index 6aa6bb2f1..9650679ac 100644
--- a/lib/designsettings.php
+++ b/lib/designsettings.php
@@ -132,13 +132,13 @@ class DesignSettingsAction extends AccountSettingsAction
_('Off'));
$this->element('p', 'form_guide', _('Turn background image on or off.'));
$this->elementEnd('li');
- }
- $this->elementStart('li');
- $this->checkbox('design_background-image_repeat',
- _('Tile background image'),
- ($design->disposition & BACKGROUND_TILE) ? true : false );
- $this->elementEnd('li');
+ $this->elementStart('li');
+ $this->checkbox('design_background-image_repeat',
+ _('Tile background image'),
+ ($design->disposition & BACKGROUND_TILE) ? true : false );
+ $this->elementEnd('li');
+ }
$this->elementEnd('ul');
$this->elementEnd('fieldset');
@@ -388,7 +388,11 @@ class DesignSettingsAction extends AccountSettingsAction
$original = clone($design);
$design->backgroundimage = $filename;
+
+ // default to on, no tile
+
$design->setDisposition(true, false, false);
+
$result = $design->update($original);
if ($result === false) {