Brian said:
I have an ASP file querying 3 fields in a database. I have noticed on
many websites that use asp is that after the <page>.asp the have a ?
and then a field name = to a value. How does this work? How can I make
it work for me?
When an HTML FORM is submitted, it supplies either a querystring or a form
collection to its ACTION, depending on whether its METHOD is "get" or
"post". Name-value pairs come from successful controls. Example:
<form action="request.asp" method="get">
<input name="name" value="bob">
</form>
This form will produce your querystring: request.asp?name=bob. In contrast,
if the form METHOD is "post", there will be no querystring, but rather a
collection of name-value pairs submitted to request.asp in the headers.
Up to this point, this is simply an HTML question...
For example one of my fields is NAME. if I have an asp page
called request.asp?name=bob then should I only get the record
for bob?
....Now it becomes an ASP one. You can process the data in request.asp by
evaluating the proper collection elements:
Request.Form("name").Item (for "post")
Request.QueryString("name").Item (for "get")
Based on your question, I suggest you find an ASP tutorial, as I am glossing
over many things to provide a succinct answer.
--
Dave Anderson
Unsolicited commercial email will be read at a cost of $500 per message. Use
of this email address implies consent to these terms. Please do not contact
me directly or ask me to contact you directly for assistance. If your
question is worth asking, it's worth posting.