473,405 Members | 2,404 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

How to play a flash movie continuously while the user browses my page?

Atli
5,058 Expert 4TB
Hi.

So I have this flash movie that plays a Mp3 file using the MediaPlayback component, which is all working wonderfully.
If the user presses a play button, the song starts to play, and I would like it to continue to do so while he is browsing around my page.

The only thing I can think of at the moment that would make this possible would be to use frames, and I'm trying to do that now, but I would rather not be stuck with that. They cause all sorts of collateral damage that I could do without.

Any suggestions would be greatly appreciated.

Thanks,
Atli Ţór.
Aug 23 '08 #1
6 3988
joedeene
583 512MB
I know this post was quite a while ago, but if you still need help, I'd recommend using the Sound.onSoundComplete event handler. If you are still working on that project, or need further assistance please let me know, and I will help you.

joedeene
Oct 28 '08 #2
Atli
5,058 Expert 4TB
Hi joedeene.

Thanks for the suggestion, but I can't really see how this event would help.

The problem is; when a client enters my page, the flash movie is loaded and the sound starts to play. If the client then decides to navigate away from that page to another section of my page, the flash movie is re-loaded and starts playing from the beginning again.

The best solution I managed to come up with was using JavaScript.
I basically created a variable containing the current position of the player within flash, which I had the JavaScript read every 250ms and save in a cookie.
Then, whenever the client entered a page, I would check that cookie and start playing from the saved position.

This is obviously a little defective, because even tho the sound would start playing from the same position, there was always a couple of seconds cap while the page loaded.

I have actually abandoned this function of the web for now. I plan to re-create the web to operate entirely client-side, using AJAX to load required data from the server, which pretty much takes care of this problem.

But thanks for the help tho.
Come to think of it... that even handler you mentioned might solve another problem I have been working on.
Oct 29 '08 #3
joedeene
583 512MB
Ohh...Ya, if you client navigates to another page it will have to reload and re-download the flash file for viewing and start again basically from frame one, I'm wondering if there is also a handler, in flash, when you leave the page you're currently browsing, then you could use something like local Shared Objects to save the position. Also, when you said 'page' I thought you meant like one specific Web Page and not like more than one or a whole website. But sorry I couldn't help...

joedeene
Oct 29 '08 #4
Fabez
29
You could use Html frames, but that would be the very last resort.
Nov 2 '08 #5
Atli
5,058 Expert 4TB
[...] then you could use something like local Shared Objects to save the position. [...]
Ahh thanks for that. This could be used to replace my previous attempt where I used JavaScript. I didn't know Flash could handle cookies.

You could use Html frames, but that would be the very last resort.
Yea, that was what I originally thought to. But like I said in my first post, I would much rather not have to fall back on that.

In any case. My new AJAX version of my web will fix all of this :)

Thanks.
Nov 2 '08 #6
Markus
6,050 Expert 4TB
You could, of course, have one of those nasty pop ups that some sites use.. but you're better than that. Go AJAX.
Feb 17 '09 #7

Sign in to post your reply or Sign up for a free account.

Similar topics

9
by: Keith Rowe | last post by:
Hello, I am trying to reference a Shockwave Flash Object on a vb code behind page in an ASP.NET project and I receive the following error: Guid should contain 32 digits with 4 dashes...
18
by: Simula | last post by:
I am developing an HTML javascript application and I want to preserve state in a way that can be book-marked. I chose HTML anchors as a means of preserving state. When the application changes...
1
by: jparker | last post by:
I have been working with ASP classic on this current project im involved in. Well the problem im facing now is there is a page where a flash movie should play in a particular section on the page...
115
by: post2google | last post by:
I was thinking about where to go for lunch the other day, so I went to hardees.com to see what the menu looked like these days. What comes up is a big note that my flash version is not new enough...
10
by: Steve Cook | last post by:
Hi, I have an upload application written in PHP and Flash. The PHP page gets the file information via $_POST. Moreover, the user never actually visits the PHP page, rather Flash sends the...
0
by: CptDondo | last post by:
I am trying to get started on a page which uses a short flash movie to show status. The flash movie itself is only a few seconds long - say 15 seconds. What I want is something like this...
2
by: jamjam19 | last post by:
Hello, I've created a Flash movie with animation as a header for my website. This movie is embedded into my "header.html" file which is called by every page on the site (by way of PHP). Is...
5
by: mratanudey83 | last post by:
With the help of this forum members and google search i've done the following part Imports AxShockwaveFlashObjects Public Class Form1 Private Sub Form1_Load(ByVal sender As System.Object,...
26
by: Jake Barnes | last post by:
I did a search on the newsgroup comp.lang.javascript. I was searching for "how to play a sound with Javascript". I'm somewhat suprised that the majority of entries are from the 1990s, and there are...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.