Closed (fixed)
Project:
Table Manager
Version:
4.6.x-1.x-dev
Component:
User interface
Priority:
Normal
Category:
Feature request
Assigned:
Reporter:
Created:
14 Nov 2005 at 14:52 UTC
Updated:
21 Nov 2005 at 09:54 UTC
Upload a CSV file to add to a table.
Comments
Comment #1
pobster commentedI'll need an example of a CSV file to work with. In my head it doesn't seem to need much code particularly?
However... I'm NOT a 'proper' programmer and I really haven't got a clue about reading from files... It might take me a few days after you provide me with an example file for me to actually figure out how to do it. I will give it a go though! I like a challenge!
Pobster
Comment #2
michelleA CSV file is just a text file with a list of comma seperated values... If you need an example, copy this to a text file:
"john doe","999 main st","anytown","usa"
"mary jane","111 1st ave","smalltown","usa"
That should translate into two records in your table with 4 fields in each.
This looks like a great module and I plan on using it if it's going to work with 4.7. I, too, could use the ability to import from CSV as the data I have in mind to use in it is currently in Excel.
Thanks for making this,
Michelle
Comment #3
pobster commentedOkay! I'll look into how to go about doing this and get back to you. Watch this space!
Incidentally, yes I'll be updating this module to 4.7 once I've started using it for my main sites (as I'll need it myself for my product listings!)
Thanks
Pobster
Comment #4
pobster commentedOkay I've finished it, and I'm glad I did it too as it's alerted me to a glaring error that I've made with the 'name' field in the tablemanager database. Fortunately as I've solved it in the CSV function it's given me a good idea of how to solve it in rest of my code and so I'll get on that right now...
To get the latest version download it from here:
http://cvs.drupal.org/viewcvs/drupal/contributions/modules/tablemanager/
At the moment it's located in the 'Attic' folder -
http://cvs.drupal.org/viewcvs/drupal/contributions/modules/tablemanager/...
I'm *really* sorry btw, but I just cannot work out how to use Drupals file.inc to import the CSV file. The manual page for it is down and I can't work it out from looking at other peoples code either... Afraid you'll have to settle with cut and paste ;o)
Let me know if this works for you - if not, I'll see what I can do. It should be okay though as I've tested it myself quite a few times.
Thanks
Pobster
Comment #5
pobster commented