% location = "products" sub_location = "product_detail" category_code = Request("category_code") category_level = Request("category_level") item_code = Request("item_code") sql_detail = "SELECT * FROM og_products WHERE p_item_code='"& item_code &"'" set rs = server.CreateObject("adodb.recordset") rs.Open sql_detail, dbcon,1 if rs.bof or rs.eof then %> <% response.end end if cur_category_name = select_category_name(rs("p_category_code")) cur_category_code = rs("p_category_code") sql_cat = "SELECT c_category_name, c_category_level, c_parent_category FROM og_categories WHERE c_category_code='"& rs("p_category_code") &"'" set rs_cat = server.CreateObject("adodb.recordset") rs_cat.Open sql_cat, dbcon,1 parent_category_code = "" parent_category_name = "" if not rs_cat.bof or not rs_cat.eof then if rs_cat("c_category_level") = 2 then cur_category_level = rs_cat("c_category_level") parent_category_code = rs_cat("c_parent_category") parent_category_name = select_category_name(parent_category_code) end if end if brand_name = select_brand_name(rs("p_brand_code")) flag_sale = "" flag_new = "" if cdbl(rs("p_price_retail_sale")) > 0 then flag_sale = "yes" item_price = rs("p_price_retail_sale") else item_price = rs("p_price_retail") end if p_description = rs("p_description") if p_description <> "" then p_description = replace(p_description,"chr_13", chr(13)) p_description = replace(p_description,"chr_9", chr(9)) end if %>