You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm developing a quiz and I've got an error with the inclusion of jQuery. In my current web application, I included jQuery directly in the includeJS {} with a jquery.forceOnTop = 1, this was necessary for technical reasons.
Currently, I am facing a problem, from ‘fp_masterquiz/Resources/Private/Templates/Quiz
/Show.html", I get an error at “var form = $(”#quiz-form'+ceuid);", the console tells me "Uncaught TypeError: $ is not a function’.
Why does this trigger this error even though jQuery is loaded correctly at the top of the page? If I include jQuery directly in the footer, then it works.
I'm using the extension in version 3.7.1, TYPO3 in version 11.5.36 and jQuery in version 3.5.1.
Thanks in advance
The text was updated successfully, but these errors were encountered:
That must mean, that jQuery is not loaded yet. I don´t know why not.
You could change the template and add the document.addEventListener('DOMContentLoaded' around the jQuery-Code:
document.addEventListener('DOMContentLoaded', function(){ var form = $(”#quiz-form'+ceuid); ... }, false);
In that case the code is executed only after the site is loaded...
Hello,
I'm developing a quiz and I've got an error with the inclusion of jQuery. In my current web application, I included jQuery directly in the includeJS {} with a jquery.forceOnTop = 1, this was necessary for technical reasons.
Currently, I am facing a problem, from ‘fp_masterquiz/Resources/Private/Templates/Quiz
/Show.html", I get an error at “var form = $(”#quiz-form'+ceuid);", the console tells me "Uncaught TypeError: $ is not a function’.
Why does this trigger this error even though jQuery is loaded correctly at the top of the page? If I include jQuery directly in the footer, then it works.
I'm using the extension in version 3.7.1, TYPO3 in version 11.5.36 and jQuery in version 3.5.1.
Thanks in advance
The text was updated successfully, but these errors were encountered: