1752782 Members
5948 Online
108789 Solutions
New Discussion юеВ

CSV to HTML

 
Patrick Ware_1
Super Advisor

CSV to HTML

Hello,

I am looking for a program or script that will convert CSV files to HTML files. Does anyone know of such a script or program?
7 REPLIES 7
James R. Ferguson
Acclaimed Contributor

Re: CSV to HTML

Hi Patrick:

Have a look at this Perl module to define a HTML table from comma-separated values.

http://search.cpan.org/~jmason/HTML-WebMake-2.2/lib/HTML/WebMake/PerlLib/csvtable_tag.wmk

Regards!

...JRF...
Mark Greene_1
Honored Contributor

Re: CSV to HTML

Here's a swiss-army-knife version:

http://home.hccnet.nl/s.j.francke/t2t/text2table.htm


mark
the future will be a lot like now, only later
Patrick Ware_1
Super Advisor

Re: CSV to HTML

Thanks guys. I forgot to mention that it needs to run on HP-UX.
Peter Godron
Honored Contributor

Re: CSV to HTML

Patrick,
James's Perl module should work on hpux.

I assume you want to convert csv to a html table, not just make it viewable via a browser, otherwise you could use the AddType command in the browser conf.
Patrick Ware_1
Super Advisor

Re: CSV to HTML

AddType? Are you referring to filters for the httpd.conf file? How would you specify that using the perl module? I have been reading the docs on apache.org regarding that.
Peter Godron
Honored Contributor

Re: CSV to HTML

Patrick,
sorry to confuse the issue.

The Perl module will convert a csv file to a html table format.

My question was whether that was what you wanted to happen i.e. csv to html table.
If you wanted to just display the csv file as text, you would use the AddType in httpd.conf. We display txt files as text on the browser, but for csv we display as spreadsheet.
Patrick Ware_1
Super Advisor

Re: CSV to HTML

That's exactly what I want. I have a script already in place to convert a XML spreadsheet to CSV. Now I need to convert the CSV to HTML.