Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    New Coder
    Join Date
    Sep 2006
    Posts
    66
    Thanks
    6
    Thanked 0 Times in 0 Posts

    How do I get xml-friendly data in my table?

    I'm trying to configure mySQL to change my data to that which can be accepted and read by an xml parser. XML-friendly data is what I need.

    I changed the mysql instance to UTF-8 (via the instance wizard) but nothing changed.

    I stll get the funny characters in my data.

    My data as is right now:
    Code:
    <song>
    <id>1003</id>
    <artist>Kenny Dope</artist>
    <album>Saint-Germain-des-Pr�s Caf� II</album>
    <title>11 - Mr. Dope</title>
    <date_added>2004-11-02 07:13:50</date_added>
    <picture></picture>
    <duration>180558</duration>
    <albumyear/>
    <buycd></buycd>
    <website></website>
    <genre>General Jazz</genre>
    </song>
    Notice the <album> element. The funny characters are actually the accented e' character.

    Is there anything I'm missing? or what do I need to do to get xml-friendly data without the funny characters?

    Thanks,

    erdubya

  • #2
    Master Coder
    Join Date
    Dec 2007
    Posts
    6,682
    Thanks
    436
    Thanked 890 Times in 879 Posts
    Quote Originally Posted by erdubya View Post
    I'm trying to configure mySQL to change my data to that which can be accepted and read by an xml parser. XML-friendly data is what I need.

    I changed the mysql instance to UTF-8 (via the instance wizard) but nothing changed.

    I stll get the funny characters in my data.

    My data as is right now:
    Code:
    <song>
    <id>1003</id>
    <artist>Kenny Dope</artist>
    <album>Saint-Germain-des-Pr�s Caf� II</album>
    <title>11 - Mr. Dope</title>
    <date_added>2004-11-02 07:13:50</date_added>
    <picture></picture>
    <duration>180558</duration>
    <albumyear/>
    <buycd></buycd>
    <website></website>
    <genre>General Jazz</genre>
    </song>
    Notice the <album> element. The funny characters are actually the accented e' character.

    Is there anything I'm missing? or what do I need to do to get xml-friendly data without the funny characters?

    Thanks,

    erdubya
    if is not a font problem then probably you don't set charset to utf-8 when your server respond to a request.
    For example main page from the link from your signature is served as iso-8859-1, plain english because don't have a charset declared.

    Code:
    Response Headers - http://projectvibe.net/
    
    Date: Thu, 23 Apr 2009 13:37:22 GMT
    Server: Apache/2.2.11 (Unix) mod_ssl/2.2.11 OpenSSL/0.9.7a mod_bwlimited/1.4 mod_perl/2.0.4 Perl/v5.8.8
    X-Powered-By: PHP/5.2.6
    Expires: Mon, 26 Jul 1997 05:00:00 GMT
    Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
    Pragma: no-cache
    Set-Cookie: 771ec4e6405146e8c93de6ade047c4f7=cb2c40b5cebc4f217d631e2425326c72; path=/
    Last-Modified: Thu, 23 Apr 2009 13:37:22 GMT
    Keep-Alive: timeout=5, max=67
    Connection: Keep-Alive
    Transfer-Encoding: chunked
    Content-Type: text/html
    
    200 OK
    best regards

  • #3
    New Coder
    Join Date
    Sep 2006
    Posts
    66
    Thanks
    6
    Thanked 0 Times in 0 Posts
    So what should I do to get xml-friendly data?

    It has nothing to do with the font.

  • #4
    Master Coder
    Join Date
    Dec 2007
    Posts
    6,682
    Thanks
    436
    Thanked 890 Times in 879 Posts
    Quote Originally Posted by erdubya View Post
    So what should I do to get xml-friendly data?
    probably is nothing wrong with xml, you can't make it more friendly, , it's enought to have a xml prolog on top of the file:
    Code:
    <?xml version="1.0" encoding="utf-8"?>
    the problem is with what you use to see the content and from where and there is no general or simple solution for that. If you get the content over the net you must be sure that is served as xml with a utf-8 encoding.

    http://www.w3.org/QA/2008/03/html-charset.html
    http://nikitathespider.com/articles/...ivination.html


    It has nothing to do with the font.
    you are probably right.

    best regards
    Last edited by oesxyl; 04-23-2009 at 05:40 PM.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •