Login   Register  
PHP Classes
elePHPant
Icontem

CSV handler error

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us

      CSV Handler  >  All threads  >  CSV handler error  >  (Un) Subscribe thread alerts  
Subject:CSV handler error
Summary:CSV handler error
Messages:5
Author:laleb
Date:2011-09-25 12:46:43
Update:2011-10-31 12:16:21
 

  1. CSV handler error   Reply   Report abuse  
Picture of laleb
laleb
2011-09-25 12:46:43
there is a problem with the length of value in CSV, if the CSV value long, code in the table are confused?

sorry for bad english...

  2. Re: CSV handler error   Reply   Report abuse  
Picture of Andreas Mueller
Andreas Mueller
2011-09-26 07:21:36 - In reply to message 1 from laleb
Hi Ialeb

in this version it reads Lines up to 3000 characters, if your data is longer it gets confused.
But this limit is arbitrary and can easily be changed, in function ReadCSV (around Line 42) there are these lines:

$this->HeaderData = fgetcsv ($fp, 3000, $this->Separator);
while ($DataLine = fgetcsv ($fp, 3000, $this->Separator)) {

Change the 3000 value to something more than your longest line.
This should not be unnecessarily high, as it affects the memory your script uses.
hope this helps

Andreas

  3. Re: CSV handler error   Reply   Report abuse  
Picture of laleb
laleb
2011-10-26 11:02:30 - In reply to message 2 from Andreas Mueller
Hi Andreas,thanks for help,
but now I have another problem, I need options to delete whole row?
Like column delete?

Thanks

  4. Re: CSV handler error   Reply   Report abuse  
Picture of Andreas Mueller
Andreas Mueller
2011-10-27 13:35:35 - In reply to message 3 from laleb
I am a bit confused, usually I would refer to rows as the "horizontal" data, whereas columns describes the vertical (contents of one Field in a record).

What do you want to delete now, and do yu want to do this with the editor interface or directly by your pscript accessing the class?


  5. Re: CSV handler error   Reply   Report abuse  
Picture of laleb
laleb
2011-10-31 12:16:22 - In reply to message 4 from Andreas Mueller
Sorry, my mistake,
I want option to delete entire columns, like button for row in class?