POST question

  • Thread starter Thread starter TR
  • Start date Start date
T

TR

MyPage.htm has <FORM ACTION="Register.aspx" METHOD="POST">. Where does
Register.aspx reference the values passed to it via the Post method in
MyPage.htm?

Thanks in advance.
TR
 
I'm not 100% sure what you are asking. But it sounds like you want to know
how to access form fields in Register.aspx? Check out the Request.Form
collection

'VB.Net
Request.Form("FieldName")

//C#
Request.Form["FieldName"];

Karl
 
Thanks, Request.Form("keyname") is where I thought it would be, but wasn't
sure. However, when I look at Request.Form.Keys.Count in the Immediate
Window, the count = 0. So, for some reason, the <INPUT> values of
MyPage.htm are not being posted to Register.aspx. I don't see anything
malformed in the HTML (see below). Is there anything special that has to be
done to the receiving ASPX page to allow it to receive values posted to it
from another HTML page?
Thanks
TR


<FORM ACTION="Register.aspx" METHOD="POST" ID="Form1">
Please enter your:<br>
Username:
<input type="text" id="uid" name="uid" style="width: 100px">
<br>
Password:
<input type="password" name="pw" id="pw" style="width: 100px">
<br>
<INPUT TYPE="submit" class="submitter" name="submitbutton"
VALUE="Logon"><br>
<input type="text" style="width: 100px;" name="cc" id="cc">
<br>
</FORM>





Karl Seguin said:
I'm not 100% sure what you are asking. But it sounds like you want to know
how to access form fields in Register.aspx? Check out the Request.Form
collection

'VB.Net
Request.Form("FieldName")

//C#
Request.Form["FieldName"];

Karl

--
MY ASP.Net tutorials
http://www.openmymind.net/


TR said:
MyPage.htm has <FORM ACTION="Register.aspx" METHOD="POST">. Where does
Register.aspx reference the values passed to it via the Post method in
MyPage.htm?

Thanks in advance.
TR
 
TR:
It works fine for me as-is...can't imagine what's wrong.

Is there a reason you aren't using only ASPX pages with the postback
capabilities of asp.net?

Karl

--
MY ASP.Net tutorials
http://www.openmymind.net/


TR said:
Thanks, Request.Form("keyname") is where I thought it would be, but wasn't
sure. However, when I look at Request.Form.Keys.Count in the Immediate
Window, the count = 0. So, for some reason, the <INPUT> values of
MyPage.htm are not being posted to Register.aspx. I don't see anything
malformed in the HTML (see below). Is there anything special that has to be
done to the receiving ASPX page to allow it to receive values posted to it
from another HTML page?
Thanks
TR


<FORM ACTION="Register.aspx" METHOD="POST" ID="Form1">
Please enter your:<br>
Username:
<input type="text" id="uid" name="uid" style="width: 100px">
<br>
Password:
<input type="password" name="pw" id="pw" style="width: 100px">
<br>
<INPUT TYPE="submit" class="submitter" name="submitbutton"
VALUE="Logon"><br>
<input type="text" style="width: 100px;" name="cc" id="cc">
<br>
</FORM>





Karl Seguin said:
I'm not 100% sure what you are asking. But it sounds like you want to know
how to access form fields in Register.aspx? Check out the Request.Form
collection

'VB.Net
Request.Form("FieldName")

//C#
Request.Form["FieldName"];

Karl

--
MY ASP.Net tutorials
http://www.openmymind.net/


TR said:
MyPage.htm has <FORM ACTION="Register.aspx" METHOD="POST">. Where does
Register.aspx reference the values passed to it via the Post method in
MyPage.htm?

Thanks in advance.
TR
 
Karl,
Thanks for testing.

To answer your question about why we're doing it this way: at some point, I
do want to convert everything to ASPX but that's not an option at the
moment. The static HTML page that posts to my ASPX page is being developed
by another team member (our art director, a non-programmer) using
Dreamweaver. He wanted to continue using a tool he was familiar with. He
makes frequent changes to the artwork and layout on that page because the
owner of the company changes his mind a lot :-)
TR

Karl Seguin said:
TR:
It works fine for me as-is...can't imagine what's wrong.

Is there a reason you aren't using only ASPX pages with the postback
capabilities of asp.net?

Karl

--
MY ASP.Net tutorials
http://www.openmymind.net/


TR said:
Thanks, Request.Form("keyname") is where I thought it would be, but wasn't
sure. However, when I look at Request.Form.Keys.Count in the Immediate
Window, the count = 0. So, for some reason, the <INPUT> values of
MyPage.htm are not being posted to Register.aspx. I don't see anything
malformed in the HTML (see below). Is there anything special that has to be
done to the receiving ASPX page to allow it to receive values posted to it
from another HTML page?
Thanks
TR


<FORM ACTION="Register.aspx" METHOD="POST" ID="Form1">
Please enter your:<br>
Username:
<input type="text" id="uid" name="uid" style="width: 100px">
<br>
Password:
<input type="password" name="pw" id="pw" style="width: 100px">
<br>
<INPUT TYPE="submit" class="submitter" name="submitbutton"
VALUE="Logon"><br>
<input type="text" style="width: 100px;" name="cc" id="cc">
<br>
</FORM>





Karl Seguin said:
I'm not 100% sure what you are asking. But it sounds like you want to know
how to access form fields in Register.aspx? Check out the Request.Form
collection

'VB.Net
Request.Form("FieldName")

//C#
Request.Form["FieldName"];

Karl

--
MY ASP.Net tutorials
http://www.openmymind.net/


MyPage.htm has <FORM ACTION="Register.aspx" METHOD="POST">. Where does
Register.aspx reference the values passed to it via the Post method in
MyPage.htm?

Thanks in advance.
TR
 
Back
Top