Javascript Events

Javascript Events

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.

Accessing the JavaScript events

  1. Click on the element you would like to customize.

  1. Click the JavaScript Events [] icon on the element property box.

  1. Specify the function to be applied when an event occurs.

 

  1. Go to Pages.

  1. Select the page in which you want the JavaScript event.

  1. Click Edit Page Info.

 

 

  1. Define the function in the corresponding page header/footer code.

  1. Click Save.

 

Sample Code:

 

  1. 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.

You can input various function names to apply different event types for any element.

 

Types of JavaScript events

We currently support six events:

  • onclick  

The click event fires when the user clicks on an element that has the listener attached.

  • ondblclick  

The dblclick event fires when the user double clicks an element that has the listener attached.

  • onmouseover  

The mouseover event fires when the user moves the mouse over an element that has the listener attached.

  • onmouseout  

The mouseout event fires when the mouse leaves an element that has the listener attached.

  • onmouseenter

The mouseenter event fires when a pointing device (usually a mouse) is moved over the element that has the listener attached.

  • onmouseleave  

The mouseleave event fires when a pointing device (usually a mouse) is moved off the element that has the listener attached.

 


    Access your files securely from anywhere

      Zoho CRM Training Programs

      Learn how to use the best tools for sales force automation and better customer engagement from Zoho's implementation specialists.

      Zoho CRM Training
        Redefine the way you work
        with Zoho Workplace

          Zoho DataPrep Personalized Demo

          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.

          Zoho CRM Training

            Create, share, and deliver

            beautiful slides from anywhere.

            Get Started Now


              Zoho Sign now offers specialized one-on-one training for both administrators and developers.

              BOOK A SESSION






                          Quick Links Workflow Automation Data Collection
                          Web Forms Enterprise Begin Data Collection
                          Interactive Forms Workplace Data Collection App
                          Offline Forms Customer Service Accessible Forms
                          Digital Forms Marketing Forms for Small Business
                          HTML Forms Education Forms for Enterprise
                          Contact Forms E-commerce Forms for any business
                          Lead Generation Forms Healthcare Forms for Startups
                          Wordpress Forms Customer onboarding Order Forms for Small Business
                          No Code Forms Construction RSVP tool for holidays
                          Free Forms Travel
                          Prefill Forms Non-Profit

                          Intake Forms Legal

                          Form Designer HR

                          Card Forms Food
                          Assign Forms Photography

                          Translate Forms Real Estate
                          Electronic Forms

                          Notification Emails for Forms Alternatives
                          Holiday Forms Google Forms alternative 
                          Form to PDF Jotform alternative





                                            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.




                                                Manage your brands on social media

                                                  Zoho Desk Resources

                                                  • Desk Community Learning Series


                                                  • Digest


                                                  • Functions


                                                  • Meetups


                                                  • Kbase


                                                  • Resources


                                                  • Glossary


                                                  • Desk Marketplace


                                                  • MVP Corner


                                                  • Word of the Day


                                                    Zoho Marketing Automation

                                                      Zoho Sheet Resources

                                                       

                                                          Zoho Forms Resources


                                                            Secure your business
                                                            communication with Zoho Mail


                                                            Mail on the move with
                                                            Zoho Mail mobile application

                                                              Stay on top of your schedule
                                                              at all times


                                                              Carry your calendar with you
                                                              Anytime, anywhere




                                                                    Zoho Sign Resources

                                                                      Sign, Paperless!

                                                                      Sign and send business documents on the go!

                                                                      Get Started Now




                                                                              Zoho TeamInbox Resources



                                                                                      Zoho DataPrep Resources



                                                                                        Zoho DataPrep Demo

                                                                                        Get a personalized demo or POC

                                                                                        REGISTER NOW


                                                                                          Design. Discuss. Deliver.

                                                                                          Create visually engaging stories with Zoho Show.

                                                                                          Get Started Now









                                                                                                              • Related Articles

                                                                                                              • Code Snippets

                                                                                                                Code snippets are small bits of code that can be added to enhance your website. With code snippets, you can insert widgets and scripts from source providers into your site. Due to security issues, you cannot preview the widget. You'll have to publish ...
                                                                                                              • Dynamic Content

                                                                                                                Dynamic content refers to website content that isn't fixed or static, but changes based on user action. Use dynamic content on your website to display data from third-party services without updating the website every single time. For example, you can ...
                                                                                                              • Register a Client with Google

                                                                                                                To configure Social Login, we first need to create a client on Google. This document explains how to register a client in Google. Create a project Head over to Google API and create an account using your email address. Check the terms of service ...
                                                                                                              • Code Customization

                                                                                                                Code snippets are small bits of code that can be added to enhance your website. You can insert widgets and script from source providers to your site. This will help the page include snippets which are most requested, and you can apply them site-wide ...
                                                                                                                Wherever you are is as good as
                                                                                                                your workplace

                                                                                                                  Resources

                                                                                                                  Videos

                                                                                                                  Watch comprehensive videos on features and other important topics that will help you master Zoho CRM.



                                                                                                                  eBooks

                                                                                                                  Download free eBooks and access a range of topics to get deeper insight on successfully using Zoho CRM.



                                                                                                                  Webinars

                                                                                                                  Sign up for our webinars and learn the Zoho CRM basics, from customization to sales force automation and more.



                                                                                                                  CRM Tips

                                                                                                                  Make the most of Zoho CRM with these useful tips.



                                                                                                                    Zoho Show Resources