RE: [PHP] fgetcsv() excel data missing
[snip] I used fgetcsv() function to get the data from a excel file. While reading the data it shows some special characters . I found the same problems in http://bugs.php.net/bug.php?id=12127edit=2 Is it a bug? [/snip] What special characters does it show? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] fgetcsv() excel data missing
Hi, Thanks for the reply. It shows ÐÏࡱá\\þÿ etc. source code I used is $handle = fopen (file.xls,r); while ($data = fgetcsv ($handle, 1000, ,)) { $num = count($data); for ($c=0; $c $num ; $c++) { $str_email = $data[$c]; echo $str_email; } } Binoy __ __ __ __ Sent via the WebMail system at softwareassociates.co.uk --- Scanned by MessageExchange.net (13:55:17 SPITFIRE) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] fgetcsv() excel data missing
[snip] Thanks for the reply. It shows ÐÏࡱá\\þÿ etc. source code I used is $handle = fopen (file.xls,r); while ($data = fgetcsv ($handle, 1000, ,)) { $num = count($data); for ($c=0; $c $num ; $c++) { $str_email = $data[$c]; echo $str_email; } } [/snip] You have to save the .xls file as a .csv file, then you can open and getcsv -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] fgetcsv() excel data missing
Thanks Jay. Could anybody please tell me how to read the data from an excel file ? It should work independent of the operating system. I don't want the csv format. Binoy __ __ __ __ Sent via the WebMail system at softwareassociates.co.uk --- Scanned by MessageExchange.net (14:20:44 SPITFIRE) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] fgetcsv() excel data missing
[snip] Could anybody please tell me how to read the data from an excel file ? It should work independent of the operating system. I don't want the csv format. [/snip] Start here http://us4.php.net/com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] fgetcsv() excel data missing
Binoy AV wrote: Thanks Jay. Could anybody please tell me how to read the data from an excel file ? It should work independent of the operating system. I don't want the csv format. excel files aren't independent of the OS, csv files are. Excel files need to be parsed, because they contain heaps of formatting data. If you're using php on a windows OS, then you can use COM or .NET to read it in. On other systems however, you'll likely run into problems pretty quickly, and will most probably need to write your own parser routine Binoy __ __ __ __ Sent via the WebMail system at softwareassociates.co.uk --- Scanned by MessageExchange.net (14:20:44 SPITFIRE) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] fgetcsv() excel data missing
On Fri, 2005-02-18 at 09:12, M. Sokolewicz wrote: Binoy AV wrote: Thanks Jay. Could anybody please tell me how to read the data from an excel file ? It should work independent of the operating system. I don't want the csv format. excel files aren't independent of the OS, csv files are. Excel files need to be parsed, because they contain heaps of formatting data. If you're using php on a windows OS, then you can use COM or .NET to read it in. On other systems however, you'll likely run into problems pretty quickly, and will most probably need to write your own parser routine Not to mention the different versions of excel that alter the format. Bret -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] fgetcsv() excel data missing
Binoy AV wrote: Could anybody please tell me how to read the data from an excel file ? It should work independent of the operating system. I don't want the csv format. For your first step, you'll have to convince Microsoft to OpenSource their code... Oh, yeah. You can't do that. :-) -- Like Music? http://l-i-e.com/artists.htm -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php