summaryrefslogtreecommitdiff
path: root/program/steps/addressbook
diff options
context:
space:
mode:
authorthomascube <thomas@roundcube.net>2011-12-20 10:21:12 +0000
committerthomascube <thomas@roundcube.net>2011-12-20 10:21:12 +0000
commitbab0433a274f4e22130793b5e77d3767492c4a9f (patch)
tree358e94dd7bd3eb015c80769aac023ee45d253f67 /program/steps/addressbook
parentc29b82d90a8bdf9ee93a1a5e28237a8e078eae74 (diff)
First steps for Larry's address book
Diffstat (limited to 'program/steps/addressbook')
-rw-r--r--program/steps/addressbook/edit.inc9
1 files changed, 4 insertions, 5 deletions
diff --git a/program/steps/addressbook/edit.inc b/program/steps/addressbook/edit.inc
index 49915f5ab..eb6aa1886 100644
--- a/program/steps/addressbook/edit.inc
+++ b/program/steps/addressbook/edit.inc
@@ -176,9 +176,8 @@ function rcmail_upload_photo_form($attrib)
{
global $OUTPUT;
- // add ID if not given
- if (!$attrib['id'])
- $attrib['id'] = 'rcmUploadbox';
+ // set defaults
+ $attrib += array('id' => 'rcmUploadbox', 'buttons' => 'yes');
// find max filesize value
$max_filesize = parse_bytes(ini_get('upload_max_filesize'));
@@ -196,10 +195,10 @@ function rcmail_upload_photo_form($attrib)
$hidden->show() .
html::div(null, $input->show()) .
html::div('hint', rcube_label(array('name' => 'maxuploadsize', 'vars' => array('size' => $max_filesize)))) .
- html::div('buttons',
+ (get_boolean($attrib['buttons']) ? html::div('buttons',
$button->show(rcube_label('close'), array('class' => 'button', 'onclick' => "$('#$attrib[id]').hide()")) . ' ' .
$button->show(rcube_label('upload'), array('class' => 'button mainaction', 'onclick' => JS_OBJECT_NAME . ".command('upload-photo', this.form)"))
- )
+ ) : '')
)
);