The SitePoint Forums have moved.

You can now find them here.
This forum is now closed to new posts, but you can browse existing content.
You can find out more information about the move and how to open a new account (if necessary) here.
If you get stuck you can get support by emailing forums@sitepoint.com

If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

How do web sites have alert boxes that tell you "You must download this first before using our site". The annoying sites you want to murder? Once you download it, they STHU?

No, I dont want to do this. I am building a game, and I want to store some images & other files on the users machine. I was hoping to make the user download the files before playing. Any ideas how those annoying sites do it?

Exactly. It is a security issue and it makes sense that a web page shouldn't have access to that kind of capabilities. If you want to do this you'll need to get your users to download and install a special separate application to do this for you. If you want to do it in IE only (and thus limit your target audience) I wouldn't be surprised is you could do it with active X. After all, since when did active X care about security?

augathra: I think your best bet would be to write a real application as a window (or otherwise) executable, which could talk to your script via the internet. Just tell your users that they have to install the game forst, don't try and just hack into their computerrs without telling them!

No, I dont want to do this. I am building a game, and I want to store some images & other files on the users machine. I was hoping to make the user download the files before playing. Any ideas how those annoying sites do it?

Give them a link to a zip file with the images for download. Then in their profile they can store the path to the images and you can have your script creating the links.
Say you save the path in the session, then you check if it is set, if yes use it, if not use the images on the server.

Haha i like the descriptions too. Thanks for the suggestion Daimaju. I was really just trying to save a small portion of bandwidth, as I wanted a fairly graphical game. I could make an installer that goes to the Program Files, but the people that have not installed it won't see the graphics.

So this brings me to another question: =)

Could I use PHP, scrambled in one of those scrambler things to hide sources, the user downloads it, sends a MySQL query to my server updating their profile. Then they could play?

But if anyone wants to tell me if it's *possible* to use a PHP file like I described above to update their status, be my guest!

If you want to have a game running on someone'scomputer... I really don't think it should be written in PHP. If it was just text based.. then yea it could be possible. Otherwise you want something that can be run on the client side, say a Flash movie of an application written in Delphi or C# or something.Delphi and C# both have tools you could use to talk to a server running a PHP script, so you could still do authentication and stuff server side using PHP.

Have a look at http://www.globulos.com/ for an example of a game written in Flash which talks to a server. Your server could be a PHP script.