Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Passing Parameters

Guest
Jun 20, 2007 Jun 20, 2007
I am building a simple record entry site without any login requirements. On the INDEX.ASP page, a user enters basic contact information (name, address, etc) into a form. I would like to link a page to this with another form that allows those new users to select from a group of checkboxes. I am unsure how to pass the USERID (keyfield) from INDEX.asp to the second page.

Any help would be really appreciated.

Thanks,
Austin
TOPICS
Server side applications
309
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
Jun 21, 2007 Jun 21, 2007
If the form posts to the second page use Request.form("userid") as the value where usrid is the name of the form field. If you want to have the value userid available for more than one page make a seesion variable out of the userid, this will help if they want to update info or for other pages. Session("UserID") = request.form("userid") put this right at the start of the code that inserts the record on the index page
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Jun 22, 2007 Jun 22, 2007
LATEST
be sure that the form has the method="post" when you use: request.form("key") when you use "get" you use: request.QueryString

linking from index1.asp to index2.asp:

index1.asp: href="domain.com/index2.asp?Key1=Hello&Key2=World

index2.asp: response.write Request.QueryString("Key1") & " " & Request.QueryString("Key2")

hope this and input from Mike helps
regards
Sebastian
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines