Loading Random Images - Problem

Hi,
I want an image being randomly loaded out of a folder, each time you access or reload my web-page.
I use this code:

filename = [“image1.swf”, “image2.swf”, “image3.swf”];
path = “file:///folder_path”;
i = filename.length;
k = Math.floor(Math.random()*i);
loadMovie(path+filename[k], movieTarget);

It works fine when I test the movie within Flash; but it is not working at all in any browser I test the movie in. I use Dreamweaver for the test.
I am really frustrated about this. If anybody can give me a hint what I`m doing wrong, or maybe a different actionscript code that solves my problem, I´d be very glad.

Thank you very much in advance
Bye
Lars