Form translator <select> avoid

3 years ago

silviustan
Member | 17
+
0
-

Hi,

Is there any way to restrict translator on form “addSelect” items? I want to do that because, if I build a select dynamic, with database data is not needed and like now is slowing app on high volume data.

PS: I use a simple custom translator based on key value pair.

Thanks!

3 years ago

silviustan
Member | 17
+
+2
-

Sorry for stupid question. Just found on documentation https://doc.nette.org/…localization

$form->addSelect(‘carModel’, ‘Model:’, $cars)
->setTranslator(NULL);