...

imageList

Garadon
04-14-2003, 07:36 PM
I made this imageList, that hold images as the name says lol :)

the Script file (http://www.the-hive.dk/~donp/scripts/imagelist.js)
Example of it in use (http://www.the-hive.dk/~donp/scripts/imageList.html)

hope its usefull for some one :)

beetle
04-15-2003, 04:12 PM
Pretty neat, but typically in a nicely scripted API like this, there's a mechanism for writing HTML to the page, whether via document.write or other.

Wouldn't it be much nicer to see code that looked like this?var images=new imageListInitalize();

images.Add('cards/1.jpg');
images.Add('cards/2.jpg');
images.Add('cards/3.jpg');
images.writeAll();

images.Delete(1);
images.writeAll();

images.Insert(1,"cards/4.jpg");
images.writeAll();

images.Update(0,"cards/7.jpg");
images.writeAll();

images.Clear();
images.Add('cards/1.jpg');
images.writeAll();The writeAll() method would be easy to make. You could also provide DOM-based options for post-load appending, or a method-or two for writing single images or images in a specified pattern or to a certian limit.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum