Link to home
Start Free TrialLog in
Avatar of Nikita Sharma
Nikita Sharma

asked on

I am getting ASP error xmlParseEntityRef: no name. Anyone can help ?

<%
response.ContentType="text/xml"
Response.Charset = "utf-8"
Response.CodePage = 65001
%>
<!-- #include file="../includes/cnf.asp" -->
<%

%>

<%

mySQL =  "select * from MEDICAL order by MED_name   "

rs.CursorLocation = 3
rs.open mySQL, myCon, 0, 1
                                          
                                          
                                          if not rs.eof then
                                          
                                                response.write("<?xml version='1.0' encoding='UTF-8'?>")
response.write("<hospital-clinics>")
                                    
                                                while not rs.eof and rowcount < 100
                                    
                                          
                                          
                              MED_name = rs("MED_name")
                              
      MED_name = Replace(MED_name , "&rsquo;" , "'")
                              
      
            
                                          
            MED_DESC = rs("MED_DESC")
MED_DESC= Replace(MED_DESC , "lsquo" , "")
MED_DESC= Replace(MED_DESC , "&" , "")
MED_DESC= Replace(MED_DESC , "rsquo;" , "'")
MED_DESC= Replace(MED_DESC , "rsquo;" , "'")
MED_DESC= Replace(MED_DESC , "ldquo;" , """")
MED_DESC= Replace(MED_DESC , "rdquo;" , """")
MED_DESC= Replace(MED_DESC , "amp;", "&#038;")
MED_DESC= Replace(MED_DESC , "#39;" , "'")
MED_DESC= Replace(MED_DESC , "nbsp;" , " ")
MED_DESC= Replace(MED_DESC, "ndash;" , "-")
MED_DESC= Replace(MED_DESC, "quot;" , """")

 MED_LOCATION = rs("MED_LOCATION")
 

 
MED_LOCATION= Replace(MED_LOCATION , "lsquo" , "")
MED_LOCATION= Replace(MED_LOCATION , "&" , "")
MED_LOCATION= Replace(MED_LOCATION , "rsquo;" , "'")
MED_LOCATION= Replace(MED_LOCATION , "ldquo;" , """")
MED_LOCATION= Replace(MED_LOCATION , "rdquo;" , """")
MED_LOCATION= Replace(MED_LOCATION, "ndash;" , "-")
MED_LOCATION= Replace(MED_LOCATION, "quot;" , """")



               MED_TEL = rs("MED_TEL")
               
 MED_TEL= Replace( MED_TEL , "lsquo" , "")
 MED_TEL= Replace( MED_TEL , "&" , "")
 MED_TEL= Replace( MED_TEL , "rsquo;" , "' ")
 MED_TEL= Replace( MED_TEL , "ldquo;" , """")
 MED_TEL= Replace( MED_TEL , "rdquo;" , """")
 MED_TEL= Replace( MED_TEL, "ndash;" , "-")
 MED_TEL= Replace(  MED_TEL, "quot;" , """")

               
               

MED_EMAIL= rs("MED_EMAIL")
MED_WEBSITE= rs("MED_WEBSITE")


                                    

response.write("<medical-detail>")
'response.write("<newsid>" & rs("news_id") & "</newsid>")
response.write("<name>" & MED_name&   "</name>")
'response.write("<number>" & MED_TEL & "</number>")

response.write("<location>" & MED_LOCATION & "</location>")
response.write("<Description>" & MED_DESC & "</Description>")
'response.write("<website>" & MED_WEBSITE & "</website>")
'response.write("<email>" & MED_EMAIL & "</email>")
response.write("</medical-detail>")


            %>
       
       
       
          <%
                  count = count + 1
                  rowcount = rowcount + 1      
                  rs.MoveNext
            
                  Wend
                  
                  %>
            <%
            end if
            rs.close
            response.write("</hospital-clinics>")
            %>
ASKER CERTIFIED SOLUTION
Avatar of Big Monty
Big Monty
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial