ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
DateTimeFilterContextRenderer.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
22
23use ILIAS\UI\Renderer as RendererInterface;
26
32{
33 protected function wrapInFormContext(
34 FormInput $component,
35 string $label,
36 string $input_html,
37 ?string $id_for_label = null,
38 ?string $dependant_group_html = null
39 ): string {
40 $tpl = $this->getTemplate("tpl.context_form.html", true, true);
41
42 $tpl->setVariable("INPUT", $input_html);
43
44 if ($id_for_label) {
45 $tpl->setCurrentBlock("for");
46 $tpl->setVariable("ID", $id_for_label);
47 $tpl->parseCurrentBlock();
48 }
49
50 $label = $component->getLabel();
51 $tpl->setVariable("LABEL", $label);
52
53 return $tpl->get();
54 }
55}
wrapInFormContext(FormInput $component, string $label, string $input_html, ?string $id_for_label=null, ?string $dependant_group_html=null)
getTemplate(string $name, bool $purge_unfilled_vars, bool $purge_unused_blocks)
Get template of component this renderer is made for.
return true
This describes inputs that can be used in forms.
Definition: FormInput.php:33
Interface to templating as it is used in the UI framework.
Definition: Template.php:29
An entity that renders components to a string output.
Definition: Renderer.php:31
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
Definition: Checkbox.php:21