A form can be filled only by an authenticated user and I want to set hidden and non hidden fields from the active (authenticated) user.
I tried Twig in Frontmatter like default: {{ grav.user.email }}
, but this did not work, even if activated in config/system.yaml.
frontmatter:
process_twig: true
ignore_fields:
- form
- forms
I tried
data-default@: '\Grav\Plugin\Login::getUser::fullname'
data-default@: ['\Grav\Common\User\User::value', 'email']
but this did not work. Is it possible to access information of authenticated user in form frontmatter? Any “How To” for me?
Thank you
Dieter
Updated 22.06.2018 for clearification.