Is there a way I can access my servoy methods from a html?
For example I am displaying this in a label that has showAs: trusted_html:
- Code: Select all
<html><a href="javascript:globals.myMethod()">ClickMe</a></html>
I have set these properties onLoad but it does not make a difference:
- Code: Select all
elements.html_label.putClientProperty(APP_UI_PROPERTY.ALLOW_JAVASCRIPT_LINK_INPUT, true);
elements.html_label.putClientProperty(APP_UI_PROPERTY.TRUST_DATA_AS_HTML, true);
It works if i set this property to false: servoy.ngclient.setContentSecurityPolicyHeader, but this is not desired.
Thank you,
Diana