aboutsummaryrefslogtreecommitdiff
path: root/lib/classes/forms/HiddenInput.php
blob: 4430d068836f5b0425854c3f139bf2d30cdb9fda (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
<?php

namespace Studip\Forms;

class HiddenInput extends Input
{
    public function render()
    {
        $template = $GLOBALS['template_factory']->open('forms/hidden_input');
        $template->name = $this->name;
        $template->value = $this->getValue();
        $template->id = md5(uniqid());
        $template->attributes = arrayToHtmlAttributes($this->attributes);
        return $template->render();
    }
}