18 lines
286 B
PHP
18 lines
286 B
PHP
<?php
|
|
|
|
class FilenameField extends TextField {
|
|
|
|
public $extension = null;
|
|
public $icon = true;
|
|
|
|
public function icon() {
|
|
|
|
$icon = new Brick('div');
|
|
$icon->addClass('field-icon');
|
|
$icon->append('<span>.' . $this->extension . '</span>');
|
|
|
|
return $icon;
|
|
|
|
}
|
|
|
|
}
|