Dear Friends,

I have a custom view helper which adds tooltips to a view.
JavaScript is needed for these tooltips so I need to add an external
JavaScript-file.
This I want to do when the view helper is called the first time -
because otherwise it is unnecessary.
Because I want to add more than only one tooltip I need to prevent
that this JavaScript-file is added multiple times.

The JavaScript-file responsible for the tooltips should be added only
when the tooltip view helper is called and this only once.
Successive calls of the view helper shouldn't result in adding the
JavaScript-file multiple times.

Now I don't know if there is already a mechanism for custom
view-helpers for doing so.
Maybe there is already something I could rely on.

Thank you for answers in advance.
With best regards
Innocentus

Reply via email to