csv2wp is a little script for converting tables from the comma-separated values (CSV) file format to wiki-tables. The idea is to provide an easy way to import tables from spread sheet applications like Excel. csv2wp is written in PHP and can thus be used with any webbrowser:
The sourcecode of this program is released under the GPL. It can be downloaded here (as a TGZ, 4,7KB): csv2wp Sourcecode.
The conversion of CSV-data requires only a few steps:
- Enter the CSV-data into the big yellowish text field at the top. There are two ways to do that:
- Use copy&paste to put the data from a text editor into the field. It is then up to the operating system and the browser to convert special characters (like umlauts, etc) correctly.
- Upload the data directly from a file. An upload-field is provided just below the text field for that purpose. You have to specify the character set for the file you upload, so that special characters can be converter correctly. In germany the most common character sets are: CP-1250 oder ISO-8859-15 (Windows), ISO-8859-1 or UTF-8 (Linux), MacRoman (Macintosh). Don't forget to click the button labeled "Upload File!" The csv-data you uploaded should then appear in the text field.
- Specify the separator character and other settings. The defaults are set to the configuration most programs (like Excel) use. For details, please see below.
- Click one of the big buttons to start the conversion. To use the table in the Wikipedia (or another Wiki), please use the MediaWiki format. To use the table in some other webpage, use HTML-format.
- The result should be shown in the browser window. You may save the data just as any webpage, by choosing the "Save Page" option. In case of the WikiMedia format, you can also just use copy and paste to put the data into the wiki. However, in case you used the HTML format, this is not possible: in that case the browser recognizes the data as HTML and interprets the code, showing a nice Table, but not the source code.
Import from Excel[Bearbeiten]
- Inside Excel, choose the Table you want to export (you can only export one table at a time). Then choose "save as" and select CSV as the file format.
- Enter the file you created into the converter-form, like described above: either open them in a text editor and just copy the data into the text field, or upload the file directly to the form.
- proceed as described above.
(ToDo - at the moment, details are available in german only)