Jump to content

PHPExcel - åäö problem


snuffish

Recommended Posts

Hi, I'm working to generate a excel file with the PHPExcel library. But I got a big problem.

The excel file will not open if the file contains the characters "åäö" (that's swedish characters).

I got this error after I have generated the file and want to open it:

 

 <?xml version="1.0" encoding="UTF-8" standalone="yes" ?> 
- <recoveryLog xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main">
  <logFileName>error021840_01.xml</logFileName> 
  <summary>Errors were detected in file 'C:\DOCUME~1\snuffish\LOKALA~1\Temp\report-46.xlsx'</summary> 
- <removedParts summary="Following is a list of removed parts:">
  <removedPart>Removed Part: /xl/sharedStrings.xml part with XML error. (Strings) Illegal xml character. Line 97, column 26.</removedPart> 
  </removedParts>
- <removedRecords summary="Following is a list of removed records:">
  <removedRecord>Removed Records: Cell information from /xl/worksheets/sheet1.xml part</removedRecord> 
  <removedRecord>Removed Records: Cell information from /xl/worksheets/sheet2.xml part</removedRecord> 
  </removedRecords>
  </recoveryLog>

 

But the problem is that the error only appears when I receive a string form the MySql database that contains those characters. It's work perfectly when I write words directly in the source.

I have tried to change all types of encoding (UTF-8/ANSI etc..) but nothing works and I have searched through the whole web. But I can't find the answer.

 

So I would be very glad if anyone could help me as soon as possible.

 

// Best regards Christoffer!

Link to comment
https://forums.phpfreaks.com/topic/171621-phpexcel-%C3%A5%C3%A4%C3%B6-problem/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.