Attaching JavaScript events to elements on your website is a great way to enhance the interactivity and user experience of your site. You can attach JavaScript events to any element in your website. JS events are any instance of interaction with the page, via mouse, keyboard, or forms. This feature requires minimal JavaScript knowledge.
Click on the element you would like to customize.
Click the JavaScript Events [] icon on the element property box.
Specify the function to be applied when an event occurs.
Go to Pages.
Select the page in which you want the JavaScript event.
Click Edit Page Info.
Define the function in the corresponding page header/footer code.
Click Save.
Sample Code:
Next, you can save and publish your site. When you click the button in your published site, the function will be applied. In this case, the alert box will appear as per the code.
We currently support six events:
The click event fires when the user clicks on an element that has the listener attached.
The dblclick event fires when the user double clicks an element that has the listener attached.
The mouseover event fires when the user moves the mouse over an element that has the listener attached.
The mouseout event fires when the mouse leaves an element that has the listener attached.
The mouseenter event fires when a pointing device (usually a mouse) is moved over the element that has the listener attached.
The mouseleave event fires when a pointing device (usually a mouse) is moved off the element that has the listener attached.
Learn how to use the best tools for sales force automation and better customer engagement from Zoho's implementation specialists.
If you'd like a personalized walk-through of our data preparation tool, please request a demo and we'll be happy to show you how to get the best out of Zoho DataPrep.
You are currently viewing the help pages of Qntrl’s earlier version. Click here to view our latest version—Qntrl 3.0's help articles.