Results 1 to 9 of 9

Thread: **Resolved** Button, Hidden Textbox and Post Method

Threaded View

  1. #1

    Thread Starter
    Giants World Champs!!!! Mark Gambo's Avatar
    Join Date
    Sep 2003
    Location
    Colorado
    Posts
    2,965

    **Resolved** Button, Hidden Textbox and Post Method

    How can I transfer data from a hidden text box to another page via the post method. Here is my code:

    Page1.asp

    VB Code:
    1. <html>
    2. <head>
    3. <title>Page1.asp</title>
    4. <h1>Page1.asp</h1>
    5. </head>
    6.  
    7. <body>
    8.  
    9. <table>
    10. <form action = "Page2.asp" Method = "Post">
    11.  
    12. <tr>
    13. <td>Mark</td>
    14. <td><Input type = "Submit" Name "LookupBut" Value = "Request Info"</td>
    15. <td><Input type = "hidden" Name "Lookup" Value = "Mark"</td>
    16. </tr>
    17.  
    18. <tr>
    19. <td>Joe</td>
    20. <td><Input type = "Submit" Name "LookupBut" Value = "Request Info"</td>
    21. <td><Input type = "hidden" Name "Lookup" Value = "Joe"</td>
    22. </tr>
    23.  
    24. <tr>
    25. <td>Peter</td>
    26. <td><Input type = "Submit" Name "LookupBut" Value = "Request Info"</td>
    27. <td><Input type = "hidden" Name "Lookup" Value = "Peter"</td>
    28. </tr>
    29.  
    30. </form>
    31. </table>
    32. </body>
    33. </html>

    Page2.asp

    VB Code:
    1. <html>
    2. <head>
    3. <title>Page2.asp</title>
    4. <h1>Page2.asp</h1>
    5. </head>
    6. <body>
    7.  
    8. <%
    9. strName = Request.Form("Lookup")
    10. %>
    11. You selected <%= strName %> 's Name
    12.  
    13. </body>
    14. </html>

    When I click on the button adjecent to Peter's Name I want to transfer the value of the hidden textbox to Page2.asp.

    I have searched the forum and I couldn't figure out how to accomplish this. Any ideas


    Thanks,
    Last edited by Mark Gambo; Sep 8th, 2004 at 01:40 PM.
    Regards,

    Mark

    Please remember to rate posts! Rate any post you find helpful. Use the link to the left - "Rate this Post". Please use [highlight='vb'] your code goes in here [/highlight] tags when posting code. When a question you asked has been resolved, please go to the top of the original post and click "Thread Tools" then select "Mark Thread Resolved."


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width