Bitrix-D7 23.9
 
Загрузка...
Поиск...
Не найдено
customconfig.php
1<?php
2
4
6
10class CustomConfig extends Config
11{
12 private ?string $html;
13
18 public function __construct(string $name, ?string $html = null)
19 {
20 parent::__construct($name, Types::CUSTOM);
21
22 $this->html = $html;
23 }
24
32 public function setHtml(string $value)
33 {
34 $this->html = $value;
35 }
36
40 public function toArray(): array
41 {
42 $result = parent::toArray();
43
44 if (isset($this->html))
45 {
46 $result['HTML'] = $this->html;
47 }
48
49 return $result;
50 }
51}
__construct(string $name, ?string $html=null)