radicalneoevo / php-excel-reader

Automatically exported from code.google.com/p/php-excel-reader
0 stars 0 forks source link

val() function returns garbage sometimes #104

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. get the particular XLS file that I have that contains sensitive information 
thus i cannot publically share it (seems to happen with any encoding i try)
2. change old existing code that uses this script from using 
$data->sheets[0]['cells'][$i][$j] to $data->val($i, $j, 0)
3. convert to CSV and check input vs output

What is the expected output? What do you see instead?

instead of the 11th and 12th columns having proper data in them, they have crap 
with missing letters and dashes and equals signs and stars, i.e. "company" -> 
"y-co-pa" and "Calgary Public Library" -> "y Pu-Ca-ga"

Please provide any additional information below.

I cannot change any settings with the spreadsheet as I'm running a PHP script 
on a Linux server that is pulling it off another server, converting it to CSV, 
then importing into an SQL database. I saw in the documentation that I should 
use the val() function instead of accessing the data directly but this seems to 
not be an option.

Original issue reported on code.google.com by RedScou...@gmail.com on 18 Jan 2011 at 10:40

GoogleCodeExporter commented 9 years ago
You sure those cells aren't formatted as date?

Original comment by rust....@gmail.com on 25 Oct 2011 at 1:41