PDA

View Full Version : Javascript array to static html


View Full Version : Javascript array to static html


flyingmunky25
October 3rd, 2008, 01:22 PM
Hi All,
I'm looking for a way to take a javascript array from a .js file, and process it to create a single html page per item in the array.
I have looked at the options of writing a script in c++ or c# or some other language to process the file, but i was wondering if anyone knew of something thats already made or a program that would do this.

Thanks!

flyingmunky25
October 3rd, 2008, 01:33 PM
i probably should have elaborated some more
This script holds a bunch of data and the html file pulls out the different elements it needs and creates a table in html.

the .js file is pretty much just a large database since we do not have any server-side scripting here or database access.

dubstylee
October 3rd, 2008, 04:17 PM
do you actually need html files or can you do a document.write

flyingmunky25
October 3rd, 2008, 09:56 PM
i actually need the html files. for whatever reason that i don't know, my job requires them. they want the pages done with the javascript and also just plain old html pages.

TorrentSearch
October 12th, 2008, 06:21 AM
Is this what you're looking for?
http://coding.derkeiler.com/Archive/Perl/perl.beginners/2004-06/0796.html
Or does it have to be Javascript?

Is this similar to what you want to do?
http://www.w3schools.com/html/tryit.asp?filename=tryhtml_basic