Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Grab Information from Text box1 and place in Text box2

Status
Not open for further replies.

Govnor

Technical User
Sep 3, 2002
55
GB
Please Help me!

Page1.asp:
I Have an asp page with a form, within this form i have a text box called text1.

Page2.asp
I have another asp page with a form, within this form i have a text box called text2.

Is it possiable?
I would like to take the Value of text1 in page1.asp and place it in text2 in page2.asp

BUT i cannot use the Post method on the form as this is used to post information else where.

Thanks,
Manraj
 
how is the form submitted? can you show the code.
it's possible to create a session variable for the value of text1 and then give the value to text2 but if you are submitting the form in some way with the use of querystrings that is not needed. can you give some detail on how the form is being processed
admin@onpntwebdesigns.com
 
PAGE1.asp code is below ---------- text box is called AP

</HEAD>
<body bgcolor=#fffece link=#aa0000 alink=#ffff00 vlink=#000066 bgproperties=&quot;fixed&quot; MARGINHEIGHT=0 MARGINWIDTH=0 TOPMARGIN=0 LEFTMARGIN=0 onLoad=&quot;initPage()&quot;><!--background=&quot;background.jpg&quot;-->
<form name=&quot;SFORM&quot; action=&quot; method=&quot;post&quot; target=&quot;_blank&quot; mode=&quot;&quot; ENCTYPE=&quot;&quot; class=&quot;&quot; dir=&quot;&quot; id=&quot;&quot; lang=&quot;&quot; onclick=&quot;&quot; ondblclick=&quot;&quot; onkeydown=&quot;&quot; onkeypress=&quot;&quot; onmousedown=&quot;&quot; onmousemove=&quot;&quot; onmouseout=&quot;&quot; onmouseover=&quot;&quot; onmouseup=&quot;&quot; onreset=&quot;&quot; style=&quot;&quot; title=&quot;&quot; onSubmit=&quot;return validate(this)&quot;>
<INPUT TYPE=&quot;hidden&quot; NAME=&quot;CY&quot; VALUE=&quot;ep&quot;>
<INPUT TYPE=&quot;hidden&quot; NAME=&quot;LG&quot; VALUE=&quot;en&quot;>
<INPUT TYPE=&quot;hidden&quot; NAME=&quot;DB&quot; VALUE=&quot;REG&quot;>
<INPUT TYPE=&quot;hidden&quot; NAME=&quot;LS&quot; VALUE=&quot;1&quot;>
<INPUT TYPE=&quot;hidden&quot; NAME=&quot;NA&quot; VALUE=&quot;0&quot;>
<TABLE ALIGN=&quot;CENTER&quot; BGCOLOR=&quot;#fffece&quot; BORDER=&quot;0&quot; CELLSPACING=&quot;0&quot; CELLPADDING=&quot;0&quot;>
<TR><br><br><br>
<TD ALIGN=&quot;CENTER&quot; ></TD>
<TD ALIGN=&quot;CENTER&quot;><B><FONT face=&quot;Arial, Helvetica, sans-serif&quot; SIZE=+2>Welcome to Mathys & Squire</FONT></B><BR></TD>
</TR>
<TD ALIGN=&quot;CENTER&quot;><B><FONT face=&quot;Arial, Helvetica, sans-serif&quot; SIZE=+2>Please enter your Application Number</FONT></B><BR></TD>
</TR>
</TABLE><br><br><br><br><br>
<script language=&quot;JavaScript&quot;><!-- // cloak

text = &quot;&quot;;
text += '\n<TABLE ALIGN=&quot;CENTER&quot; BGCOLOR=&quot;#fffece&quot; BORDER=&quot;5&quot; CELLSPACING=&quot;0&quot; CELLPADDING=&quot;0&quot; WIDTH=600>\n<TR><TD>';
text += '\n<TABLE BGCOLOR=&quot;#fffece&quot; WIDTH=&quot;100%&quot; CELLSPACING=&quot;5&quot; CELLPADDING=&quot;0&quot;>';
text += '\n<TABLE BGCOLOR=&quot;#fffece&quot; background=&quot;background.jpg&quot; WIDTH=&quot;100%&quot; CELLSPACING=&quot;5&quot; CELLPADDING=&quot;0&quot; border=0>';
text += ' \n<TR><TD COLSPAN=3> </TD></TR>';
text += ' \n<TR>';
text += ' <TD ALIGN=&quot;right&quot;><A HREF=&quot;javascript:;&quot; onClick=&quot;return openWindow(\'help/312.htm\')&quot; onMouseOver=&quot;return st(me[1])&quot; onMouseOut=&quot;return st()&quot;></A> <FONT FACE=&quot;Arial, Helvetica, sans-serif&quot; SIZE=&quot;-1&quot;>'+pe[1]+'</FONT></TD>';
text += ' <TD ALIGN=&quot;CENTER&quot;><INPUT SIZE=&quot;20&quot; MAXLENGTH=&quot;255&quot; NAME=&quot;AP&quot; VALUE=&quot;&quot;></TD>';
text += ' <TD><FONT FACE=&quot;Arial, Helvetica, sans-serif&quot; SIZE=&quot;-2&quot;>'+ee[1]+'</FONT></TD>';
text += ' </TR>';
text += ' <TD ALIGN=&quot;center&quot; COLSPAN=&quot;3&quot;><FONT FACE=&quot;Arial, Helvetica, sans-serif&quot; SIZE=&quot;-1&quot;><br>'
text += ' <INPUT TYPE=&quot;submit&quot; NAME=&quot;theSubmit&quot; VALUE=&quot;'+se+'&quot;> <INPUT TYPE=&quot;reset&quot; VALUE=&quot;'+ce+'&quot; onClick=&quot;this.form.AP.focus()&quot;> <INPUT TYPE=&quot;button&quot; VALUE=&quot;'+me[9]+'&quot; onClick=&quot;return openWindow(\'text += ' </TR>';
text += ' \n<TR>';
text += ' <TD ALIGN=&quot;center&quot; COLSPAN=&quot;3&quot;> </TD>';
text += ' </TR>';

theUrl = new Array(&quot;&quot;,&quot;&quot;); urlCount=0;
lg = new Array(&quot;en&quot;,&quot;de&quot;,&quot;fr&quot;);
lang = new Array('English','Deutsch','Français');
if (&quot;ep&quot; == &quot;ep&quot;) {
for (i=0;i<3;i++) {
if (lg == &quot;en&quot;) continue;
theUrl[urlCount++] = '<a href=&quot;/espacenet/ep/'+lg+'/srch-reg.htm&quot; TARGET=&quot;_top&quot;>'+lang+'</a>';
}
}
text += ' \n<TR>';
text += ' <TD ALIGN=&quot;center&quot; valign=&quot;middle&quot;><FONT FACE=&quot;Arial, Helvetica, sans-serif&quot; SIZE=&quot;-1&quot;>';
text += ' </font></TD>';
text += ' </TR>';
text += '\n</TABLE>';
text += '</TD></TR>\n</TABLE>';
document.write(text);
// uncloak --></script>
<center> <a name=&quot;U.S. Associates&quot; id=&quot;U.S. Associates&quot; href=&quot;Email.asp&quot; target=&quot;main&quot;>U.S. Associates Email</a> </center>
<center>
</FORM>
</BODY>



Page2.asp is below ----------- text box is called subject

<html>
<head>
<SCRIPT LANGUAGE=&quot;JavaScript&quot;>

</script>
</head>
<body>

<FORM ACTION=&quot;email.asp&quot; METHOD=&quot;post&quot;>

Enter your e-mail address:<BR>
<INPUT TYPE=&quot;text&quot; NAME=&quot;from&quot; SIZE=&quot;30&quot;></INPUT>

<!-- These would be used if we decided to let you edit them-->
Subject:
<INPUT TYPE=&quot;text&quot; NAME=&quot;subject&quot; SIZE=&quot;30&quot;></INPUT><BR>

Message:
<TEXTAREA NAME=&quot;body&quot; ROWS=&quot;10&quot; COLS=&quot;40&quot; WRAP=&quot;virtual&quot;>
 
in your page that you post the information to create a session variable and give it the value of the textbox, then jsut fill the text box with the value of that session variable.
example
in the beginning of this page
do
session(&quot;value&quot;) = Request.Form(&quot;value&quot;)

then you can use the session variable to fill the text box
<INPUT TYPE=&quot;text&quot; NAME=&quot;subject&quot; SIZE=&quot;30&quot; value=&quot;<% response.write session(&quot;value&quot;) %>&quot;>


admin@onpntwebdesigns.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top