www.webdeveloper.com
Results 1 to 2 of 2

Thread: need to pass value of a text feild in a variable in ASP

Hybrid View

  1. #1
    Join Date
    Jul 2008
    Posts
    29

    need to pass value of a text feild in a variable in ASP

    Hi

    I need to pass value of a text feild in a variable.

    like I have this text feild

    Code:
    <input name="part1" type="text" id="part1 "class="style14" size="11" value="<%=objRS("part1")%>">
    rightnow value is coming from database. my user can change this value to his own and can press update button.

    this is the button I have created:

    Code:
    <input name="submitvalues" type="submit"  value="Update Request" ; onclick= "location.href='RMAdetails1.asp?req_no=<%=objRS("req_no")%>'">
    if somehow I can get the value of the text feild in a variable then i will pass it to the next page. Next page is exact replica of this asp page just its performing the update query in addition.

  2. #2
    Join Date
    Nov 2007
    Location
    Ohio
    Posts
    308
    I don't know where you found that code example but you should be using a FORM to submit data to a database.

    Code:
    <form method="post" action="RMAdetails1.asp?req_no=<%=objRS("req_no")%>">
    <input name="part1" type="text" id="part1 "class="style14" size="11" value="<%=objRS("part1")%>" />
    <input name="submitvalues" type="submit"  value="Update Request" />
    </form>

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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



Recent Articles