-
Can I send the HTTP HEAD command from Flash to a server and then check for the 200 or 304 response to determine if the file on the server has been modified since it was last checked?
-
Hi,
NO - flash does not allow to create your own requests. Depending on the browser the requests sent will be GET or GET with an If-modified-since
If you need to know the status of a particular file, you will have to use some script
Musicman
-
Hey,
you can do it by using the socket component.
1. Simply create a Socket. [mysocket = new XMLSocket();]
2. Connect to the WebServer on port 80 [mysocket.connect("myserver.com",80);].
3. Send your request [ mysocket.send("GET / HTTP/1.1\nHost: myserver.com\n\n"); ]
4. Data is received, you can process it by [ mysocket.onData(src) {
trace("answer is ".src);
}
Cabra
-
Originally posted by cabra
Hey,
you can do it by using the socket component.
1. Simply create a Socket. [mysocket = new XMLSocket();]
2. Connect to the WebServer on port 80 [mysocket.connect("myserver.com",80);].
3. Send your request [ mysocket.send("GET / HTTP/1.1\nHost: myserver.com\n\n"); ]
4. Data is received, you can process it by [ mysocket.onData(src) {
trace("answer is ".src);
}
Cabra
We are trying to put a Flash app on 500 users desktops and while we want the Flash apps to check in with the server as often as possible to find new info we do not want to overload the server.
Do you think the method you mentioned would be less server intensive than using LoadVariables to grab a small text file every time we want to check for new info on the web site?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|