classic asp if statement issue

diorges12

New Member
I have a if statement which I am pretty sure it is correct and should work. But for some reason it is not.\[code\]while not oRs2.EOFif iCat = oRs2("id") then%> <div class ="<%= oRs2("id") %><%= iCat %>"><%else%> <div class ="faqquestion <%= oRs2("id") %><%= iCat %>"><%end if%>\[/code\]And this is what you get.\[code\]<div class="faqquestion 11"><div class="faqquestion 21"><div class="faqquestion 31">\[/code\]but what it should be\[code\]<div class="11"><div class="faqquestion 21"><div class="faqquestion 31">\[/code\]cant see what i am doing wrong, 1 does = 1!?how the variables are being set:\[code\]dim iCatiCat = request.QueryString("cat")dim sSQLsSQL = "Select * from table" set oRs2 = oConn.Execute(sSQL) \[/code\]
 
Back
Top