<%@ language=vbscript codepage="65001" %> <% Response.Charset = "UTF-8" c_area1 = deal_str_beforesql(request("area1")) if c_area1="" then c_area1="" c_area2 = deal_str_beforesql(request("area2")) csql = "SP_QUERY_CIRCUITRY '" & c_area1 & "','" & c_area2 & "'" set rs=conn.execute(csql) c_rtn = "{""code"":""0"",""info"":""""," & vbcrlf c_rtn = c_rtn & " ""product_list"":[" & vbcrlf c_rtn1 = "" c_citylist = "@苏州|@常州|@溧阳|" c_sightspotlist = "@千岛湖|@常州恐龙园|@天目湖|@乌镇|@灵山大佛|@同里|" c_num1 = "" c_num2 = "" c_num3 = "" c_num4 = "" c_num5 = "" do until rs.eof c_rtn1 = c_rtn1 & " {" & vbcrlf c_rtn1 = c_rtn1 & " ""prod_code"":""" & rs("prod_code") & """," & vbcrlf c_rtn1 = c_rtn1 & " ""prod_name"":""" & rs("prod_name") & """," & vbcrlf c_rtn1 = c_rtn1 & " ""price"":""" & rs("price") & """," & vbcrlf c_rtn1 = c_rtn1 & " ""start_area"":""" & rs("start_area") & """," & vbcrlf c_rtn1 = c_rtn1 & " ""end_area"":""" & rs("end_area") & """," & vbcrlf c_rtn1 = c_rtn1 & " ""run_info"":""" & rs("go_run_info") & """," & vbcrlf c_rtn1 = c_rtn1 & " ""back_run_info"":""" & rs("back_run_info") & """," & vbcrlf c_rtn1 = c_rtn1 & " ""run_count"":""" & rs("run_count") & """," & vbcrlf c_rtn1 = c_rtn1 & " ""direction"":""" & rs("direction") & """," & vbcrlf c_rtn1 = c_rtn1 & " ""if_bus"":""" & rs("if_bus") & """," & vbcrlf c_rtn1 = c_rtn1 & " ""if_hotel"":""" & rs("if_hotel") & """," & vbcrlf c_rtn1 = c_rtn1 & " ""if_sightspot"":""" & rs("if_sightspot") & """," & vbcrlf c_rtn1 = c_rtn1 & " ""run_days"":""" & rs("run_days") & """" & vbcrlf c_rtn1 = c_rtn1 & " }," c_citylist = rs("city_list") c_sightspotlist = rs("sightspot_list") c_num1 = rs("TOTAL_COUNT") c_num2 = rs("SINGLE_COUNT") c_num3 = rs("GOBACK_COUNT") c_num4 = rs("SIGHTSPOT_COUNT") c_num5 = rs("HOTEL_COUNT") rs.movenext loop rs.close if right(c_rtn1,1)="," then c_rtn1 = left(c_rtn1,len(c_rtn1)-1) c_rtn = c_rtn & c_rtn1 c_rtn = c_rtn & " ]," & vbcrlf c_citylist = replace(c_citylist,"@","{""city"":""") c_citylist = replace(c_citylist,"|","""},") c_citylist = left(c_citylist,len(c_citylist)-1) c_citylist = """city_list"":[" & c_citylist & "]," c_rtn = c_rtn & c_citylist c_sightspotlist = replace(c_sightspotlist,"@","{""sightspot"":""") c_sightspotlist = replace(c_sightspotlist,"|","""},") c_sightspotlist = left(c_sightspotlist,len(c_sightspotlist)-1) c_sightspotlist = """sightspot_list"":[" & c_sightspotlist & "]," c_rtn = c_rtn & c_sightspotlist c_rtn = c_rtn & """total_count"":""" & c_num1 & """," c_rtn = c_rtn & """single_count"":""" & c_num2 & """," c_rtn = c_rtn & """goback_count"":""" & c_num3 & """," c_rtn = c_rtn & """gobacksight_count"":""" & c_num4 & """," c_rtn = c_rtn & """singlehotel_count"":""" & c_num5 & """" c_rtn = c_rtn & "}" & vbcrlf response.write c_rtn %>