Quitter
  • Communauté internationale
    • Langue:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티

Loading a swf in another swf and video play problem

Nouveau ici ,
Sep 24, 2010 Sep 24, 2010

image1.jpg

So i have an HTML page (in folder Subdirectory 1) and i embed 2.swf (in folder Subdirectory 2 (both folders are located in Parent Directory)).

2.swf loads 1.swf from Subdirectory 1.

In 1.swf i have a video player( which loads video1.flv from videos folder) and if run individually it plays without any problem.

If I run the html it loads both swf's but the video does not play because of a "Stream.NotFound" exception.

This arrangement of files and folders is a requirement for my project. So, please can you tell me, why this behaviour occures and if there is a way out from this.

SUJETS
ActionScript
825
Traduire
Signaler
Directives de la communauté
Restez bienveillant et courtois, ne vous attribuez pas la paternité des créations d’autrui et assurez-vous de l’absence de doublons avant de poster du contenu. En savoir plus
community guidelines

correct answers 1 bonne réponse

LÉGENDE , Sep 24, 2010 Sep 24, 2010

Looks like it is not very intelligent requirement/architecture to have assets all over the place. If you cannot convince people that created this architecture to get real, you can play with relative paths and, maybe, use LoaderInfo.loaderURL to get to the videos folder since it looks like videos folder is a subdirectory of the folder where 1.swf resides.

Traduire
LÉGENDE ,
Sep 24, 2010 Sep 24, 2010

Looks like you use relative path. Relative path is relative to browser url - not the directory from which swf is loaded. Try to use absolute path.

Traduire
Signaler
Directives de la communauté
Restez bienveillant et courtois, ne vous attribuez pas la paternité des créations d’autrui et assurez-vous de l’absence de doublons avant de poster du contenu. En savoir plus
community guidelines
Nouveau ici ,
Sep 24, 2010 Sep 24, 2010

This would be a great solution, but i can't use an absolute path in this project. All paths must be relative to the html page.

Traduire
Signaler
Directives de la communauté
Restez bienveillant et courtois, ne vous attribuez pas la paternité des créations d’autrui et assurez-vous de l’absence de doublons avant de poster du contenu. En savoir plus
community guidelines
LÉGENDE ,
Sep 24, 2010 Sep 24, 2010

Looks like it is not very intelligent requirement/architecture to have assets all over the place. If you cannot convince people that created this architecture to get real, you can play with relative paths and, maybe, use LoaderInfo.loaderURL to get to the videos folder since it looks like videos folder is a subdirectory of the folder where 1.swf resides.

Traduire
Signaler
Directives de la communauté
Restez bienveillant et courtois, ne vous attribuez pas la paternité des créations d’autrui et assurez-vous de l’absence de doublons avant de poster du contenu. En savoir plus
community guidelines
Invité
Sep 24, 2010 Sep 24, 2010

I believe it is possible to do that, but sometimes it can get confusing. I think the path to the video should be relative to the HTML page. However it seems that is what you are doing, so I don't know what to say.

Traduire
Signaler
Directives de la communauté
Restez bienveillant et courtois, ne vous attribuez pas la paternité des créations d’autrui et assurez-vous de l’absence de doublons avant de poster du contenu. En savoir plus
community guidelines
Invité
Sep 24, 2010 Sep 24, 2010
LA PLUS RÉCENTE

Why not get the relatvie path by slicing the path for 2.swf and then working backwards?

Traduire
Signaler
Directives de la communauté
Restez bienveillant et courtois, ne vous attribuez pas la paternité des créations d’autrui et assurez-vous de l’absence de doublons avant de poster du contenu. En savoir plus
community guidelines