There are 4 different HTML pages namely: "HomePage.html", "ABCpage.html", "Page1.html" & "Page2.html".
HomePage.html - In this page there are 2 links both when clicked are redirected to 'ABCpage.html'. The following is the HTML code below.
<body>
<a href="ABCpage.html" id="page1">Page 1</a>
<a href="ABCpage.html" id="page2">Page 2</a>
</body>
ABCpage.html - In this page there is only an input button named 'Enter', which when clicked should redirect either to "Page1.html" or "Page2.html" depending on the link choosed from "HomePage.html"
<body>
<form method="post">
<input type="submit" id="submit" value="Enter" />
</form>
</body>
"Page1.html" and "Page2.html" are just blank pages.
So what should I do to redirect from "ABCpage.html" to either "Page1.html" or "Page2.html" depending on the links chosen from "HomePage.html". Now I am purely using javascript for client side scripting and JSP for server side scripting and am not familiar with jquery. Now the link that I choose from "HomePage.html" should directly affect the form action in "ABCpage.html" for redirecting it further either to "Page1.html" or "Page2.html" depending on the link chosen. So what could be the javascript code for the following as I am finding it hard to get a solution for this.