From 9100bb14b323c9ede76f1a037d74e70bb7386928 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Julien=20Fastr=C3=A9?= Date: Fri, 2 Sep 2016 08:26:18 +0200 Subject: [PATCH] fixing the call on js function --- Resources/views/Form/fields.html.twig | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Resources/views/Form/fields.html.twig b/Resources/views/Form/fields.html.twig index 56f5b8733..b25ec65cd 100644 --- a/Resources/views/Form/fields.html.twig +++ b/Resources/views/Form/fields.html.twig @@ -76,7 +76,9 @@ }); } - jQuery(document).ready(initializeCFChoiceOptionsChoices('{{ form.vars.id }}')); + document.addEventListener('DOMContentLoaded', function(event) { + jQuery(document).ready(initializeCFChoiceOptionsChoices('{{ form.vars.id }}')); + }); {% endblock cf_choices_row %}