mirror of
https://github.com/nextcloud/server.git
synced 2026-06-08 16:26:59 -04:00
Have a fancy uploadavatar button
This commit is contained in:
parent
9500109349
commit
d7e6c77e20
2 changed files with 6 additions and 1 deletions
|
|
@ -157,6 +157,10 @@ $(document).ready(function(){
|
|||
}
|
||||
};
|
||||
|
||||
$('#uploadavatarbutton').click(function(){
|
||||
$('#uploadavatar').click();
|
||||
});
|
||||
|
||||
$('#uploadavatar').fileupload(uploadparms);
|
||||
|
||||
$('#selectavatar').click(function(){
|
||||
|
|
|
|||
|
|
@ -90,7 +90,8 @@ if($_['passwordChangeSupported']) {
|
|||
<img src="<?php print_unescaped(link_to('', 'avatar.php').'?user='.OC_User::getUser().'&size=128'); ?>"><br>
|
||||
<?php if ($_['avatar'] === "local"): ?>
|
||||
<em><?php p($l->t('Your avatar has to be a square and either a PNG or JPG image')); ?></em><br>
|
||||
<input type="file" class="inlineblock button" name="files[]" id="uploadavatar" value="<?php p($l->t('Upload a new avatar')); ?>">
|
||||
<div class="inlineblock button" id="uploadavatarbutton"><?php p($l->t('Upload a new avatar')); ?></div>
|
||||
<input type="file" class="hidden" name="files[]" id="uploadavatar">
|
||||
<div class="inlineblock button" id="selectavatar"><?php p($l->t('Select a new avatar from your files')); ?></div>
|
||||
<div class="inlineblock button" id="removeavatar"><?php p($l->t('Remove my avatar')); ?></div>
|
||||
<?php elseif ($_['avatar'] === "gravatar"): ?>
|
||||
|
|
|
|||
Loading…
Reference in a new issue