penguinspeaks
Technical User
My simple statement is not sending to the correct place.
here is code:
just so you know the variables, and I have tested the results are
dm= 2478556480
rsv = 1500000
Now I cannot use Cint as the DM variable is too much.
The issue is this.... the page redirect is going to the premium2.asp page when you can clearly see that the dm variable is higher.
Why is this doing this??
the whole code is...
As you can see I have tested every possible variable result so the accuracy is there.
of course I will have it do other functions prior to sending to second page but I am testing as I go and am stuck here.
any help PLEASE??
here is code:
Code:
if cStr(rsv) > cStr(dm) then
response.redirect "premium2.asp?id="&var1&""
else
response.redirect "voucher_success.asp?id="&vid&""
end if
just so you know the variables, and I have tested the results are
dm= 2478556480
rsv = 1500000
Now I cannot use Cint as the DM variable is too much.
The issue is this.... the page redirect is going to the premium2.asp page when you can clearly see that the dm variable is higher.
Why is this doing this??
the whole code is...
Code:
<%
var1 = request.form("id")
'response.write var1
set info1 = conn.execute("select Premiumv, darkmatter from uni1_users where id = "&var1&"")
ps=info1.fields.item("Premiumv").value
dm=cstr(info1.fields.item("darkmatter").value)
var2 = request.form("premium")
pu = info1.fields.item("premium_until").value
var2 = cint(request.form("premium"))
'response.write var2
'response.write pu
'response.write var3
'response.write dm
if var2 = 7 then
rsv = 250000
elseif var2 = 14 then
rsv = 400000
elseif var2 = 30 then
rsv = 750000
elseif var2 = 90 then
rsv = 1500000
elseif var2 = 180 then
rsv = 2500000
end if
'response.write rsv
if cStr(rsv) > cStr(dm) then
response.redirect "premium2.asp?id="&var1&""
else
response.redirect "voucher_success.asp?id="&vid&""
end if
%>
of course I will have it do other functions prior to sending to second page but I am testing as I go and am stuck here.
any help PLEASE??