figo2476 Posted June 19, 2008 Share Posted June 19, 2008 Hi: I have a flash photo gallery. What it does is to load external xml, which contains locations of images. * It works well, when it is accessed via decent url e.g. http://domain/test/gallery/display.swf so /test, /gallery are folders in the server * But it is accessed via e.g. http://domain/controler/action (Model view controller pattern for example) The flash appears, but it cannot display images and it seems it can't find the xml file. I wonder do you guys have the same problem or is there any way to get around. Link to comment https://forums.phpfreaks.com/topic/110878-how-to-embed-flash-in-html-with-php/ Share on other sites More sharing options...
0perator Posted June 19, 2008 Share Posted June 19, 2008 erm, check the .fla file, it might not be pointing to the right directory for the images, not sure though. Link to comment https://forums.phpfreaks.com/topic/110878-how-to-embed-flash-in-html-with-php/#findComment-568913 Share on other sites More sharing options...
JADASDesigner Posted June 19, 2008 Share Posted June 19, 2008 THree things to check. all silly, but important. First, make sure the images are uploaded. It sounds retarded but it happens to me mor than I care to mention. Make sure that you FLA script is pointed to a relative address, and not an external URL. Flash has a security set up where it will not pull from other URLs for some reason. You can create a proxy in PHP if this is the problem. Lastly, if the XML file is local, then keep it in the same folder as the SWF. Link to comment https://forums.phpfreaks.com/topic/110878-how-to-embed-flash-in-html-with-php/#findComment-568918 Share on other sites More sharing options...
figo2476 Posted June 21, 2008 Author Share Posted June 21, 2008 Reply to JADASDesigner: * Images are uploaded. * XML file is at xml/images.xml and the swf file is next to xml/ The relative path inside the .swf is set to xml/images.xml to load images. * Here is my guess: When using relative path in flash, the swf will depend on the decent url, which user accesses. So flash can figure the actual path by adding the decent url + relative path. e.g. http://domain/test/gallery/display.swf But if it is used in some php framework (e.g. phpcake), the relative path won't work, since it is wrong. e.g. http://domain/controler/action/display.swf Link to comment https://forums.phpfreaks.com/topic/110878-how-to-embed-flash-in-html-with-php/#findComment-570719 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.