Javascript :: Update Client Status To Server On "onbeforeunload" Event?
Sep 2, 2010
I have a flash application that needs to send a http request to the server which will disconnect the existing session immediately. I have a tried a few options but none is reliable.Option #1: On "onbeforeunload" event send a http request from inside the flash applications. Fallacy: This does not work because as soon as the browser is closed the flash player unloads the app and hence the communication breaks.Option #2: On "onbeforeunload" event send a http request using XMLHTTPRequest in ajax. This works fine in IE but doesnt work in Firefox. When i debugged the http req in httpfox it threw "NS_BINDING_ABORTED" error which i think means that request was cancelled due to page unload.
View 2 Replies
Similar Posts:
Feb 12, 2010
I have a Flash movie embeded with swfobject in a html container. Through ExternalInterface I have registered a javascript function to fire callback to my flash app.
ExternalInterface.addCallback("notifyClose", notifyOnClose );
The javascript function is added as an event listerner to fire onbeforeunload.
<script language="JavaScript">
function getSWF(movieName) {
if (navigator.appName.indexOf("Microsoft") != -1){
[Code].....
I have tested in FF and IE. Firefox works as expected but not in IE. In IE I get notified in Flash with the onload message, but not onbeforeunload.
View 1 Replies
Nov 3, 2011
I have a ColdFusion function which sends analytics called from a Flex sendPageAnalytics() function to a SQL database when the user navigates - this works perfectly.What I am trying to do is have the Flex application send a bunch of analytics when the user closes their browser, therefore providing information about the last navigation.
I have used an ExternalInterface callback and listener for window.onbeforeunload and a trace statement tells me that this is working fine.My problem is that when all bundled together, I get as far as tracing out that the sendPageAnalytics() function has been called, but I do not get a sendPageAnalyticsFaultHandler() trace or a sendPageAnalyticsResultHandler() trace, which I do on every other sendPageAnalytics() call.
View 1 Replies
Nov 17, 2011
I am deploying Updates via SCUP and SCCM to hundreds of Computers. Fortunately Adobe provides an SCCM Update Catalog for both Adobe Flash ActiveX and Adobe Flash Plugin. But now my Problem: After publishing the Update via SCCM, the client is not supposed to be interfered with the Update Progress (which is working) I figured the Updater works like this: First SCCM checks if a Update needs to be deployed, if this is the case, The Flash Updater begins. First the old Flash Version is beeing uninstalled. But now: if the Client has a Browser Window (IE, or Firefox) open, the Updater is not able to install the new Flash Version and quits with an Error. This leaves the Client PC without any Flash (because its being uninstalled before) How can I prevent Flash being uninstalled due to the Update progress not working while a Browser window is open?
View 1 Replies
Mar 8, 2012
We're writing a flash application that can download a MP3 file, convert it to a Sound object, get the raw data and make some processing (like adding sounds, change octaves). After the processing, we want to send the data back to the server in chunks, so the server will be able to glue the data together and recover the new generated file. The problem is: if we send to the server "wav" pieces of sound, we are able to glue them together without any problem in the generated file. However, if we convert each wav piece to a mp3 file (so we can send a smaller file to the server) and join the mp3 files at the server, the result is a sound with some problems at the merge point.
This is how we load the mp3 file from the server:
sourceSnd.load(new URLRequest("sample url to mp3"));
sourceSnd.addEventListener(Event.COMPLETE, carregou);
This is how we convert each piece of mp3 to bytearray and wav:
[Code]....
View 1 Replies
Aug 7, 2009
A client connected to the FMS for playing live video.The problem has been found that when FMS shutdown the network, the client's NetConnection didn't dispatch any event.But when the client shutdown the network the client's NetConnection will dispatch NetConnection. Connect.Closed event.How could flash client know the FMS' server side networking problem? Does it necessary to use heartbeat mechanism between FMS and client?
View 1 Replies
Mar 2, 2010
I want to update a twitter status from a textbox in flash and use a button CLICK to pass the status to twitter. It goes like this:
[Code]...
The problem is in my languages we have 3 extra characters called. So in twitter I get this error message: Invalid Unicode value in one or more parameters So the problem is that I have to pass my String as utf-8, I think so at least. Is it a way to URL encode a String in as3?
View 5 Replies
Oct 27, 2010
how can I find on fms server that client disconnected if if client disconnected due to power cut off. I client manually close the application then onDisconnect on server is called but if due to power cut off it does not called.
View 1 Replies
Oct 29, 2009
I know this is one of those taboo things to ask, but I am all out of ideas. I have an online eLearning Module I created a few months ago. Its working great everything is wonderful. I am now working on a new one and I can for the life of me NOT make the stupid thing update the "complete" status at the proper time...
I ALSO can not find my original FLA file so I can see what I did in the ActionScript to make it work. I am positive I am missing something stupid but I have NO idea what it is. does anybody know of a good Flash Decompiler. I'm more then happy to chat with anybody to verify I am the creator of BOTH movies if your concerned about that ...
View 0 Replies
Jan 29, 2005
I am making a site for a tattooist and they need to update the gallery of tattoo images (jpg) about 4 or 6 times a year. I am making it in flash mx.I thought back to things i'd heard about and came to the conclusion that xml might be the best way with this - so the client can open a text file and change the image name and then upload the image as needed to the server.
View 2 Replies
May 22, 2011
The stream can be buffering,playing or closed.How can I capture these events while playing?
View 1 Replies
Jun 29, 2010
i have a small LAN of about 8 computers all of which are running windows 7. I have installed FMS and XAMPP webserver on one of the machines. I want to stream live from one PC to all the other PCs on the LAN. I have a webpage with jwplayer embedded in it on my XAMPP webserver that is able to see the live stream when i start it locally. I mean the live stream works fine on the machine with the servers on it. But when i want to view the live stream from another machine in the LAN by accessing the webpage that has the jwpalyer from another machine, The jwplayer returns "server not found:rtmp://192.168.10.1/live" error. I was thinking that maybe a firewall is blocking the 1935 port but i have turned off the firewall of every PC on the LAN. I have unistalled any antivirus program on all the PCs. But i still get the same error when i try to access the live stream from another PC on the LAN.When i run netstat -a -n|find ":1935" i get 192.168.10.2:49184 192.168.10.1:1935 SYN_SENT and i think the request for the stream is sent but the conection is rejected.
This is the code for the webpage with jwplayer embedded in it. maybe it:
<html>head> <title>JW FLV Media Player</title> <script type="text/JavaScript" src="swfobject.js"></script>
[code].....
View 3 Replies
Jan 8, 2010
i am new on steaming & flash server; when we try to use RTMP over HTTP the outside client gets the internal IP address of the FMS server instead of the NAT one or public IP address, how can we solve this.
View 1 Replies
Apr 18, 2010
I have created a script for an Adobe FMS application to broadcast a playlist of video files as a live stream. (internet tv)
I am now working on a custom Flash-based video player to play my stream.
How do I send information from my server-side FMS application (main.asc) to the client-side video player? (e.g: title, duration of current video player)
View 2 Replies
Sep 6, 2010
I understand how clients use bandwidth detection etc to dynamically switch streams via client calls with ns.play2( ... ), but I was wondering if it's possible to only ever use 1 initial ns.play( ... ) call on the client side, but let FMS server side logic that I write dictate which client sees what content. For example, I have 3 clients connected to my FMS server, all watching a live stream. I then decide I want clientA to see 'recordedMovieA.flv', clientB to continue seeing the live stream, and clientC to watch 'recordedMovieB.flv'.
[Code]...
View 5 Replies
Apr 7, 2010
i am currently playing around with a flash media server trial in combination with the flowplayer.All in all i am testing the performance and general functionality for the company i work for.Anyways, i am trying to search a way to check the bandwidth of a client ( server sided ) and redirecting him to the right video stream.Sure this could be done by the backend flash application, but its out intention to perform this check server sided.
View 4 Replies
Sep 19, 2010
I want to limit server recorded netstream length to 10 secs at client side using as3. How can I do that?
View 2 Replies
Apr 28, 2010
I m working in flex3.0 and i just want to know that how can i call a function from fms server to my AS3.0 (Client Side) code.i tried the syntax client.call(methodname,null,null); but my flex code throw exception unable to call the method.here can i use clientobject.call (methodname,null,null) and is there some special way to declare that method at client side.
View 3 Replies
Oct 9, 2011
No I have installed fms4.5, but I can't find good docs how to set something like this up. In Learning section I saw a lesson, but this one isn't ready.So I want to publish using flash and the subscribers to the livestream can be iPhones or Browsers.
View 13 Replies
Apr 28, 2011
i have a website like ustream, where user can register and create live channels and publish live video using FMLE.
Now i want to check wether a particular channel is online or offline. I have stream name for particular channel. My website is coded in PHP. I have tried using getLiveStreamStats function, it works fine where the XML file is not heavy. I mean number of subscribers are less. Then i can just check the Publisher Tag. if it exists that means stream video is live, else not.
But problem arrives when the number of subscribers are high. The XML file do not loads in PHP, and it takes too much time to load the page.
what can be done to just check if the xml file has publisher tag. and display if the stream is live or not
View 12 Replies
Jan 3, 2012
I want to retrieve the list of live stream name.
View 1 Replies
Apr 4, 2011
I am looking for a free plugin in flash or flex or something else that will allow me read pdf files and which I can integrate in my website. Do you know some?
UPDATE: I get the impression my question wasn't clear enough so,I am developing a website using asp.NET and I have a requirement to display a pdf file to the user so he could read the file and paging between files.I am looking for an open source plugin that I can integrate in the website. I don't really mind the technology of the component - but I prefer something in flash or flex.My problem is that the web application will run on a computer without an internet so I need something I can download and use without internet connection.
View 8 Replies
Apr 27, 2011
I'm building a server-side API and client-side library for a JavaScript-based game where two very important features must be secured. A user must be debited for each play We must ensure that the score that gets submitted is the actual earned score by the player. Solving the first problem seems simple; at the beginning of each play we hit the API, debit the user's account and return a unique Play ID. When we submit the user's score for that play, we pass the ID issued at the beginning.
The second one has me a little stumped. Initially I considered a client-side hashing algorithm based on the ID and the score, but quickly realized that the Javascript that produces the hash could easily be reverse-engineered, even if it was obfuscated. At this point I considered a small flash component that generates the hash, but I've heard that even compiled flash can be decompiled.
[Code]...
View 5 Replies
Mar 26, 2010
I would very much like to determine the IP# of a domain from client script. It's for use in a testing application to determine whether or not a certain domain is set to a QA address as opposed to the address live on the . The testing machine will have it's host file set to resolve a domain to the QA address.Pinging from the server won't help since the server is getting the public DNS address.
View 1 Replies
Mar 4, 2012
Is it possible to make cross request from client web page to any other host? using flash, javascript or mb some other client side technology, how can this cross requests ipmlemented?
View 1 Replies
Sep 19, 2009
I'm writing a script where I need flash to check the content of flashvars more than once.Does anyone know if I can reload or something flashvar in actionscript? whats the command for this?
View 2 Replies
Dec 17, 2010
I got a IP Communications new account having following paramters:
[Code]...
Its showing me connecting ... Status is not getting update like: "Connection Failed" or "Connection Success". how to use the above information in this app,
View 1 Replies
Jul 7, 2011
I am trying to learn JavaScript and I am wondering whether JavaScript has a event listener just like ActionScript's ENTER_FRAME. Basically, I want this event listener to listen "all the time" not just wait for any particular instance (mouse click, keyboard event) of event.
View 3 Replies
Aug 13, 2010
We want a web app that allows a user to edit images on the browser and we're trying to decide which technology to use. We want to support simple image customization, such as high-quality resizing, cropping, image merging, and color transformations, as well as the addition of text elements with different fonts and colors.
The current options are: Flash: no worries about cross-browser compatibility; could use same image library on client and server; no iPhone/iPad support. Java (compiled to javascript with GWT): need to find a good image library in pure Java so it can be compiled to JS. Plain old javascript + HTML5: may be a mess due to multiple browsers; may need to write image editing code from scratch. Here's what's most important to us / criteria for choosing:
Image consistency: the image that the client edits on the browser must be exactly the same as the one we'll eventually use on the backend. We can achieve this by (a) having the same library both on the client and server to process images, (b) having the client generate the image and upload it to the server, or (c) use two different image processing libraries on the client/server and hope for the best in terms of consistency.
Option (a) seems best, but it would only be possible if we use Flash or Java/GWT. We don't like option (b) because the images are large; we'd rather save a sequence of operations to perform on a raw image than saving multiple transformed images. And we don't really know if option (c) is safe or not. Scalability: We prefer the client to do as much work as possible to decrease server load. Image quality must be kept high
Cross-platform: We'd like to support as many platforms as possible without rewriting everything (big negative for Flash due to iPhone/iPads).
View 3 Replies
Nov 2, 2011
Today I heared something weird from someone, he said that using Javascript at the front end with Oracle DB that gives high performance than the performance if used Flash(ActionScript) with Oracle, while MySQL have the same performance with any client side scripting. Is that right?, Does client side scripts have anything to do with DBMS ?
View 1 Replies