Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP General > Posting form

Reply
Thread Tools

Posting form

 
 
Allwyn
Guest
Posts: n/a
 
      08-25-2003
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

 
Reply With Quote
 
 
 
 
KLomax
Guest
Posts: n/a
 
      08-25-2003
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>
</HTML>

>-----Original Message-----
>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
>
>.
>

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
posting to a form with no form name scripteaze@gmail.com Python 3 11-02-2007 08:29 AM
Top Posting vs. Bottom Posting scaredkitty Computer Support 37 04-06-2005 12:27 AM
Posting form content to remote servers form? Rob Meade ASP .Net 0 12-01-2004 12:56 PM
Everytime I hover cursro over a posting, it crosses out with red mark on it.. on every posting alanb ASP .Net 2 04-23-2004 02:23 PM
WebClient form Posting with form name? Jeff Baker ASP .Net 2 08-29-2003 12:22 PM



Advertisments