I would like help converting this code from lua to html. Would anybody know how to assist me with this? http://pastebin.com/45NyPxmt What I need to do is be able to define a table as;

name = {}
name[1] = { "hero", "type", "icon" }

and then be able to call it in a function, and also I want to know how to call global functions from other files like if I have a function in one file and I want to call it in another file, is it possible to just do something like include("file") and it will just include everything in it, or what is the deal in html?

Thanks.