homepage Welcome to WebmasterWorld Guest from
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member

Visit PubCon.com
Home / Forums Index / Code, Content, and Presentation / Apache Web Server
Forum Library, Charter, Moderators: Ocean10000 & incrediBILL & phranque

Apache Web Server Forum

Character encoding issue

 7:41 am on Oct 23, 2009 (gmt 0)

Not quite sure this is the correct forum, but I'll try :)

I am trying to use a Google Earth kml xml file originally created on my PC (used to display a route on a Google Earth Map)on my webserver. It doesn't work.

When I upload the file to my server and try to validate via feedvalidator.org I get several error messages for example this: Your feed appears to be encoded as "UTF-8", but your server is reporting "US-ASCII"

But how do I handle this? Should I convert the file from the PC to ASCII before uploading, and if yes how? Or do I need to change some settings on the server, and if the latter, is this done in apache/PHP?




 2:16 pm on Oct 23, 2009 (gmt 0)

Make sure that you have MIME-type and Content-Encoding declarations for .kml filetypes on your server. See the Apache mod_mime AddType and AddEncoding directives.



 3:09 pm on Oct 23, 2009 (gmt 0)

Thanks Jim. That helped me a bit of the way. I have tried to add the below code in an .htaccess file in the particular folder:

AddType application/vnd.google-earth.kml+xml kml
AddType application/vnd.google-earth.kmz kmz

Now, a call to a .kml file in the directory makes it open via the Google Earth application on the PC. It seems to work o.k. from a PC, but not from a Joomla GE plugin run on the server.

The script still validates as before when validating via feedvalidator.org.

Have not been able to find out how to possibly use AddEncoding. Could you possibly advice on the syntax for a .kml file?


 3:35 pm on Oct 23, 2009 (gmt 0)

Sorry, I cited AddEncoding, but intended to cite AddCharset:

AddCharset UTF-8 .kml

There are likely very few contributors here who are familiar with Joomla GE, so if you need help with that, I'd suggest a Joomla-focused forum, rather than waiting here (possibly forever) for a response to questions about your plug-in.


Global Options:
 top home search open messages active posts  

Home / Forums Index / Code, Content, and Presentation / Apache Web Server
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved