|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Passing checkbox value to other asp page
I have a simple problem:
page 1: <input type=checkbox name=addValue value="Y"> page 2: <input type="hidden" name="addValue" value="<%=Y%>"> page3: <%=request.form("addValue")%> <%if "addValue" = "Y" then addTax="30,00" else addTax="0,00" end if%> <%=pCurrencySign & (addTax)%> There is a problem in transfering the value from page 1 to page 2 and 3. What is the problem here??? |
|
#2
|
||||
|
||||
|
ASP is different from the way PHP or Perl work.
Quote:
Should be page 2: <input type="hidden" name="addValue" value="<%=Request("AddValue")%>"> Similar to what you did in page 3 |
|
#3
|
|||
|
|||
|
<input type="hidden" name="addValue" value="">
as you can see, if I look into view source in second page, value have not been transffered if I use your code. Any idea??? |
|
#4
|
|||
|
|||
|
Quote:
Do just like you did on page 3. Code:
<input type="hidden" name="addValue" value="<%=request.form("addValue")%>">
That should do it for you. |
|
#5
|
|||
|
|||
|
How to write this using sessions only???
|
|
#6
|
|||
|
|||
|
Umm I'm not sure what you mean. Maybe this is what you are looking for:
Code:
<input type="hidden" name="addValue" value="<%=Session("addValue")%>">
Session("NAME") works the same as any variable. Session("NAME") = "blah foo bar blah" sets it, and X= Session("Name") sets X = to it. |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ASP Programming > Passing checkbox value to other asp page |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|