jasonrogena / jasonrogena/php-excel-reader

Can't read xls file.

Open
#111 0 comments 0 reactions 0 assignees View on GitHub
auto-migrated Priority-Medium Type-Defect
Dominant language
PHP
Stars
1
Forks
0
PR merge metrics
No merged PRs in 30d

Description

```
I am setting up an automated procedure to read data from an xls file.
If I try to read it directly from the original file i get:

The filename asd.xls is not readable.

I've figured out that the condition that is leading to this error message is:

substr(this->data,0,8) != IDENTIFIER_OLE
(for the read method in the OLERead class) At around Line 115.

The thing is... if I open up the file in Excel and do a save as to a new file,
i am able to read that new file. Needless to say this doesn't work for an
automated process ;-). I don't know enough about excel, but I'm guessing the
version of the original file is too old, perhaps?

This is my code:

val(2,2);
?>

Any help/advice would be greatly appreciated !!

C.

```

Original issue reported on code.google.com by `carlosma...@gmail.com` on 24 Mar 2011 at 5:41

Attachments:
- [asd.xls](https://storage.googleapis.com/google-code-attachments/php-excel-reader/issue-111/comment-0/asd.xls)

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with excel_reader2.php and OLERead around line 115; reproduce the failure with the attached asd.xls and compare it with the file saved by Excel. Determine why the original file fails the IDENTIFIER_OLE check, then verify the reader handles it without requiring a manual Save As.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
data
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.