ActionScript 2.0 :: Set Flash Time From Server?
Mar 9, 2008Set flash time from server?
View 3 RepliesSet flash time from server?
View 3 RepliesWhat I am trying to accomplish is two simple analogue world clocks (which I had already done using Jquery) but IE has turned out to be the biggest nightmare to get this working correctly in - so I am trying a different avenue.
I have written a small script to retrieve server times which is below:
var ldr:URLLoader = new URLLoader()
ldr.load(new URLRequest("http://chronos.csr.net"))
ldr.addEventListener(Event.COMPLETE, onLoaded)
function onLoaded(evt:Event){
[Code].....
do take into account DST as this was a slight pitfall I had even with JS (would have worked it out eventually but time is not on my side - excuse the pun).
I have this clock code and would like to know what needs to be added or changed for it to reference the time off the server and not the local computer time (and preferably reference the server just once and not repeatedly). I already have a file on the server "time.php" that is providing the milliseconds. I know it should be fairly simple, but I just can't wrap my head around it.
[Code],,,
I'm testing Live streaming with FMSS. The stream is pushed to FMSS buy Adobe FMLE software. Streaming works fine until I reach 1300-1400 simultaneous connections.No matter what the encoding ratebit is (150kbps or 2000kbps) the stream is no longer play from time to time (5-8 seconds).
The CPU (2xIntel Quad) is loaded less than 20% and memory used is about 2 GB (there is plenty of memory installed 32G). The OS is RedHat 5.3 64bit platform. Network uplink maximum rate is 4Gbps.I disabled the Queue but the problem still persist.
make a clock base on given time(server time) as title,
View 2 Repliesevery login ,flash get server time from php. how can i update time and date in flash..?
View 3 Repliesobtain the time (by functions similar to getSeconds) of the server the flash file is hosted on, instead of the client who is viewing the movie?
Thing is, I have a very simple clock that displays the time in New Zealand (where I will be going), but it only display the time correctly for GMT+1 right now. If a client from New Zealand or US connects, they will see the wrong time :/
So right now i use:
Code:
newtime = timedate.getSeconds() + 3600*11;
timedate.setSeconds(newtime);
is there any simple way to get the server time as a variable into Flash?
View 3 Replies"Flash Clock with the server's time using PHP".
View 1 RepliesI'm seeing lots of cool clocks made in flash, but they load the time based on your machine's date and time. I want to construct a clock which takes the time from an official time server so it will always be up to date.
View 2 RepliesI'm trying to get a flash clock (with the clock hands ticking over) to work with server side time, not client side time
I understand I need "loadvars" within the actionscript for it to get time from the server but I really don't know where to start with the scripting.
I also understand I need a php script to interact with the flash file. Would the gettime.php script suffice?
Does flash provide an api to deal with remote stream like IP camera does?
View 2 RepliesI'm trying to get the time from the server (php) and then display a different flash movie (via either a different swf or frame on timeline) accordingly.
Unfortunately I haven't found anything that relates to this using as3.
how would i get the server time from the server and not from the users computor.here is my countdown script im using but its getting client time not server time.
ActionScript Code:
var currentYear:Number = new Date().fullYear;
var targetDate:Date = new Date(currentYear, 11, 50);[code]......
i know i need php but what would the php code be.and how would i implement the server time from php into the code above.
How does the url of FMS real time video stream look like?
View 1 RepliesI want to display the digital clock in my project which should display the server time.
View 2 RepliesI've used the .fla provided within this tutorial - this is also found here - to get a countdown that gets its time from the server, as opposed to the time of the clientHowever, making no alterations (other than the year to make it current), it doesn't work, as it alters when you change your computers local timeI have verified this with a friend in the USA, and within another test file where the countdown was set to 8pm server time, it was both showing 8pm for each of us (when i'm GMT and he is EST - 5 hours difference)I have uploaded the files within the same directory on our server, and have also changed the server.load url from both the default 'gettime.php' to a more specific url ofjust in case that made a difference, but alas notHere is the php file used:
PHP Code:
<?php
echo "time=" . time();
[code].....
I am making a website and they are asking for displaying two different time zones. Website will be deployed at USA server. So want to calculate according to that. I don't want to get the system time of the PC
View 1 RepliesI have a countdown script that pulls the users time, but I need the server time so visitors can't cheat the clock.[code]How do I get the server date and pass it to the date var startTime?
View 3 RepliesI'm using the following code to attempt to get netStream.time on the serverside.....i've tried various ways googled it but have come up short...what code do i need to use so i can track a streams progress from the server side?
myStream = Stream.get("home1");
setInterval(time,5000,myStream.time); function time(myStream){ trace(myStream); }
i am trying to stream to clients at the same time..Meaning they all recieve the stream at the same time and it stops at the same time.
View 1 RepliesI am sending a request to a server. If i didn't get a response i need to send a request once again after 3sec. Like this i have to check for 3 times. If 3 rd time also it fails i need to terminate the request by prompting a msg to customer.
View 1 Repliesusing old AS2 code on an fms project.it seems that both server-side NetStream object and client-side NetStream object do not have a totalTime property.my goal is to determine when the flv has completed playing ( has reached the end visually );so I figured that comparing time to totalTime would work but there appears to not be a totalTime.
View 3 RepliesI have been searching around for help or a link to a tutorial that will have a movie clip that reacts with the server time and changes or moves according to certain times, allowing me to add a couple of tweens on the specific times.
View 0 RepliesI have a REGISTERED Flash media server version with update 1 and when i try to start it I have this error in the evnet log : "FMS has detected system time is going backwards;shutting down server" i try to reinstall it, the system clock is ok
View 5 RepliesI am developing a video player for FMS 3.0 and my client complains that when he leaves the player running overnight or after computer goes to sleep when he comes back the elapsed time displayed as NaN and when he tries to play, nothing happens. Why is this happening? Does it mean that the connection with the FMS dropped and I have to reconnect? How can test for the dropped connection?
View 2 RepliesFor some reason connecting to Flash Media Server 3.5 takes around 40 seconds. The server is running on Windows Server 2008 (64-bit edition) on a virtual server located in a reliable hosting center and I'm connecting to it over the internet. The server is using built-in Windows Firewall with all the inbound TCP ports required by Flash Media Server opened (80, 1935 and 1111).
If I disable the server's firewall the connection time drops to 20 seconds, but it's still pretty damn long time just for establishing connection. We probably have some company firewall at this end (the client side), but other streaming media services works just fine over this connection.
My swf is playing one video in using NetConnection, NetStream and Video object. If I want to stream one more video simultaneously in the same swf I have a few problems. It works when I create more NetConnection, NetStream and Video objects but is that necessary? The code rapidly becomes complex to handle.
Is there an easier way like perhaps share the NetConnection, or something (same FMS server)?
Question 2
The two videos on the stage are suppose to have different size, placement etc. Still the last one created inherit the properties of the first video display. It also starts playing for an annoying couple of seconds before the first one. How can I avoid that (inherit and delay)?
var ns1:NetStream;
var ns2:NetStream;
var nc1:NetConnection = new NetConnection();
[Code].....
I have developed a Player where I am using FMS to play MP3 files, it works great in normal scenario but when user keep on clicking new songs from Song List (List Component) then the player stated playing all songs. Which It should not do. Is there a way that we can unload previous song before loading new song.
View 5 RepliesAs far as I know that the DVR function can be triggered by either check mark the "DVR auto Record" at the FMLE or by using the DVRControllerSynch. but I have a hardware device (not a computer software) that stream the video to the server How can I force DVRcast to run the DVR feature all the time?
View 4 Replies