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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Querystring confusion 1

Status
Not open for further replies.

SlakeB

MIS
Jun 15, 2005
40
US
The asp page I'm working with has a query string fed into it, and the URL is:

replyToThread.asp?MainThreadNum=14

On that page, I have a form with this code:
Code:
<form method="get" action="scriptSubThread.asp">
	<table>
		<tr>
			<td align="right">
				<input type="hidden" name="MainThreadNum" value="<%request.querystring("MainThreadNum")%>" >
			</td>
			<td align="left">
				Content: <input type="text" name="Content">
			</td>			
		</tr> 
		<tr>
			<td>
				<input type="submit" value="submit"> 
			</td>
		</tr>
	</table>
</form>

If I type "hey" in the "content" text box and click submit, the browser goes to:
scriptSubThread.asp?MainThreadNum=&Content=hey

As you can see, MainThreadNum has no value. I want to pass the same MainThreadNum from the previous page's QueryString on to this page.

What am I doing wrong??
 
that is because you are missing the =

value="<%[red]=[/red]request.querystring("MainThreadNum")%>" >
-DNG
 
glad to be of help...sometimes we all miss these small things...

-DNG
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top