-
FEATURED COMPONENTS
First time here? Check out the FAQ!
Hello everybody! I'm using ZK 9.6.0.1, I need to insert a new .js file in the <head> tag of the generated html. How can I do this?
Thank you.
Hello there!
This was actually discussed in last week's public training!
The short answer is, you have 3 ways to insert a script into the head of the generated HTML.
One a single page: You can use a processing instruction: https://www.zkoss.org/wiki/ZUMLReference/ZUML/ProcessingInstructions/script
Globally through your whole application: you can use lang-addon: https://www.zkoss.org/wiki/ZKClient-sideReference/Language_Definition/javascript
From Java: you can add arbitrary tags before or after the ZK generated headers, by getting the page, casting it as PageCtrl and using addBeforeTags or addAfterTags https://www.zkoss.org/javadoc/latest/zk/org/zkoss/zk/ui/sys/PageCtrl.html#addAfterHeadTags-java.lang.String-
Asked: 2022-10-21 00:47:03 +0800
Seen: 7 times
Last updated: Oct 24 '22
Facing issue in masking on phone [closed]
coerceFromString_ override no longer works from 6.5.1 [closed]
Execute Javascript on component visible
Is there a way to resolve view model properties as input to client side javascripts?
scrollbar listner for 2 grid [closed]
Theme javascript wpd file not found