Animation through buttons | SoloLearn: Learn to code for FREE!


Animation through buttons

What if I want to trigger an animation by pressing a button ? What and how should I use for the code given below :-

6/9/2018 3:51:50 AM

Hemant Jaiswal

6 Answers

New Answer


Calviղ Beat me to it. Yes, perfect example. Cheers


Use Javascript and an html <form>. You can also make the div the button as well, without having a separate button. More JS 😬



Anthony Quick Calviղ Rahul George Thanks guys, this will definately help me 😊


Hemant Jaiswal Cheers! :)

+4 A sample codepen project: