Im trying to create a json formated string in asp classic that I simply want to write on the page and then I get that in as a callback in my js file and parse it there and it works if I only use string text like this
response.write "{""Firstname"":""John"",""Lastname"":""Hogan""}"
But if I try to use variables with values from my db for the john an Hogan values something like this I can't get it to work?
fname="John"
lname="Hogan"
response.write "{""Firstname"":""""&fname&"""",""Lastname"":""""&lname&"""}"
Do I really need to use a json library like jsonObject.class.asp?
Any input really appreciated. Thanks!