How to call a html page to a button click

Let us say i have

<form id="editFirst" action="editFirst.html" method="POST">

I want to call by this button below Let me know how that can achieved

<input type="button" value="Main "  class="Rights">

Thank you
Who is Participating?
Marco GasiConnect With a Mentor FreelancerCommented:
If you're using jQuery, you can simple add a listener:

<input id="editFirstButton" type="button" value="Main "  class="Rights">

    $('#editFirstButton').on('click', function(){
}); //end jquery

Open in new window

Pratima PharandeCommented:
not able tp copy jabascript function here
Pratima PharandeCommented:
Create one Javascript function and type this

window.location.href = "";
The 14th Annual Expert Award Winners

The results are in! Meet the top members of our 2017 Expert Awards. Congratulations to all who qualified!

chaitu chaituCommented:
function clickRights()

<form id="editFirst" action="editFirst.html" method="POST">

<input type="button" value="Main "  class="Rights" onClick='clickRights()'>

Open in new window

Rajiv Lochan PadhiSoftware ProgrammerCommented:
<input type="button" value="Main "  onclick="location.href='editFirst.html';" class="Rights">

Open in new window

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.