Posting form

A

Allwyn

The code below doesn't work. Any help would be
appreciated. I need to force the form to submit via post
method, rather than response.redirect("Page2.asp?.....")
which doesn't post the form.

Page1 has form called "frm"

Page1 has a href link, like this, <a href="Page1.asp?
tab=aa">click here</a>

When it reloads Page1, after clicking link,

Select Case tabid
case "aa"
ViewDetail
---other case statements--
End Select


Sub ViewDetail
<SCRIPT LANGUAGE=vbs>
frm.action = "Page2.asp?tabid=ccc&Act=200"
frm.submit
</SCRIPT>
End Sub
 
K

KLomax

See if this code helps...
Regards

<HTML>
<body>
<form id="frmThis" name="frmThis">
<INPUT id="cmdPost" onclick="javascript:CallPage
('Test2.asp')" type="button" value="Post Page">

<SCRIPT LANGUAGE="javascript">
//<!--
function CallPage(pageName){
alert(pageName);
document.frmThis.method = "post" ;
document.frmThis.action = pageName ;
document.frmThis.submit() ;
}
//-->
</SCRIPT>

</form>
</body>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,022
Latest member
MaybelleMa

Latest Threads

Top