mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
git-subtree-dir: community_server git-subtree-mainline: ff11f6efe35bba180260fe84077bcd94298895c1 git-subtree-split: b6544b9e69fb85d4da100934675323c3e8c8ef67
42 lines
1.8 KiB
PHP
42 lines
1.8 KiB
PHP
<?php
|
|
|
|
/*
|
|
* To change this license header, choose License Headers in Project Properties.
|
|
* To change this template file, choose Tools | Templates
|
|
* and open the template in the editor.
|
|
*/
|
|
|
|
$this->assign('title', __('Profil ändern'));
|
|
// In a View class
|
|
$this->loadHelper('Form', [
|
|
'templates' => 'horizontal_form',
|
|
]);
|
|
?>
|
|
<div class="action-form">
|
|
<div class="form-body">
|
|
<?= $this->Form->create($profileForm, ['enctype' => 'multipart/form-data']) ?>
|
|
<?= $this->Form->control('first_name', ['label' => __('Vorname'), 'placeholder' => 'Vorname', 'value' => $user['first_name']]) ?>
|
|
<?= $this->Form->control('last_name', ['label' => __('Nachname'), 'placeholder' => 'Nachname', 'value' => $user['last_name']]) ?>
|
|
<?= $this->Form->control('profile_img', ['type' => 'file', 'accept' => 'image/*', 'label' => __('Profilbild')]) ?>
|
|
<?php if ($communityProfile['profile_img']) : ?>
|
|
<label class="form-label"> </label>
|
|
<div><img class="edit-profile-img" src="data:image/*;base64,<?=base64_encode($communityProfile['profile_img'])?>"/></div>
|
|
<?php endif; ?>
|
|
<?= $this->Form->control('profile_desc', ['label' => __('Beschreibung'), 'rows' => 4, 'placeholder' => 'Beschreibung', 'value' => $communityProfile['profile_desc']]) ?>
|
|
<?= $this->Form->button(__('Daten speichern'), ['name' => 'submit', 'class' => 'form-button']) ?>
|
|
<?= $this->Form->end() ?>
|
|
</div>
|
|
</div>
|
|
<?php // adding scripts vendor and core from ripple ui for validation effect ?>
|
|
<?= $this->Html->script(['core', 'vendor.addons']); ?>
|
|
<script type="text/javascript">
|
|
(function ($) {
|
|
'use strict';
|
|
$('textarea').maxlength({
|
|
alwaysShow: true,
|
|
warningClass: "badge badge-warning",
|
|
limitReachedClass: "badge badge-error"
|
|
});
|
|
})(jQuery);
|
|
</script>
|