[wp-hackers] XML controlled SWF files
viniciusandre at gmail.com
Tue Mar 23 12:50:47 UTC 2010
On Tue, Mar 23, 2010 at 1:44 AM, Jeremy Visser <jeremy at visser.name> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> On 23/03/10 11:39, Vinicius Massuchetto wrote:
>> I'm parsing a page for every local MP3 URL on it, and building a XML
>> file to be read by a SWF player. The player works nice out of
>> Wordpress on any host, but once we put it on the theme directory with
>> the XML, it doesn't work.
> Read your web server log files. I also highly recommend Wireshark 
> for diagnosing issues such as this. It's important that you figure out
> the differences between the static and dynamic XML files by comparing
> them directly.
> Can you load the dynamic XML file in a web browser? What HTTP headers
> are different? Are they both being served as text/xml, or is one
> text/plain or even *shudder* text/html?
>> I imagine this XML entries always need to be in a relative path from
>> the SWF file, so maybe it has something to do with Wordpress blocking
>> relative paths inside themes.
> First I've heard of that. Flash won't fetch stuff from an alternative
> domain unless it is whitelisted in that domain's crossdomain.xml file,
> but there are no subdirectory restrictions that I'm aware of.
>  http://www.wireshark.org/
Thanks for your attention.
The solution I found:
1) The path SWF looks for the XML is the page URL, not the folder the
SWF file is. So it is needed to give the full XML path to the load
function into its action:
2) The same with paths inside the XML. It is needed to always fill
references with the full path;
3) It is recommended to use Kimili Flash Embed Plugin , once it
e.g.: [kml_flashembed movie="<?php bloginfo('template_directory');
?>/swf/file.swf" wmode="transparent" width="300" height="300"]
Well.. that's it. I also posted this on the forum topic I just pasted above.
More information about the wp-hackers