CSV Field Display GUI

I need to add one of them to the project. Is there an open source PHP project for this? Do not want to reinvent the wheel.

enter image description here

+6
source share
2 answers

Possible implementations of what you request include

  • Quick CSV import with visual display

    This is a complete implementation with visual display, although it does not have a theme like your photo. An example of use is available here.

  • jQuery csv2table

    This is a partial implementation that converts csv to html table data. The rest would be to convert the generated table to SQL with a visual display

The following elements are partial PHP implementations that display csv in sql without providing a visual display to the user.

+8
source

Sometimes it’s good to reinvent the wheel, you get what you need and what you only need

It seems easy, at first you need csv kinda parser, but it's too simple, you can do something like:

Your task can be divided into:

1.- Import csv: (Create a download form, process the file extension.

2.- Store csv somewhere temporarily (Store the file, possibly with a hash instead of a name, so there are no conflicts

3.- Disassemble the csv. (http://php.net/manual/en/function.fgetcsv.php will be your friend)

4.- Two input fields, one for parsed files and one for your map, use some javascript fancyness sessions to add the correct columns on the fly

5.- Then save the mapped columns with real csv values.

+2
source

Source: https://habr.com/ru/post/911409/


All Articles