look at this piece of code in vbscript (remember that vbscript is apparently a non-typing language) :
-----
intValue1 = request.form("value1") ' 88
intValue2 = request.form("value2") ' 133
..
hundreds of lines of html mixed with vbscript
..
if intValue1 < intValue2 then
response.write("right")
else
response.write("wrong")
end if
-----------------------------------
you would expect to get 'right' as 88 is less than 133 but vbscript being a Pile of Crud treats the values as strings so that 88 is somehow more than 133 - wtf?!?!
in perl I wouldn't have to worry about numerical operations on values because perl has scalars that work. vbscript however means you have to be sure that you have cast a variable to int before doing any numerical operations on it to avoid unpredictable and nasty behaviour.
EDITED :: I think the reason this happens is because sometimes rather than fetched directly from the form values the values are pulled from an array created by splitting a string. Nonetheless they should be treated as numbers when numerical operations are done on them - and to make matters worse now when I add cint to all the lines where the form.request values are fetched I get a type mismatch - in a typeless language ffs!!
bah!!!
Nonetheless they should be treated as numbers when numerical operations are done on them...
But the point is that <
(I assume that's the missing operator in your example) isn't a numerical operator, right? VBScript doesn't have separate <
and lt
operators, so (like PHP) it has to use the type of the operands to figure out what sort of comparison to do, and URL parameters are always going to start as strings. What else could it do?
Or am I missing something? I've only written VBScript once.