PDA

View Full Version : dataset problem


Arkos
09-27-2005, 03:47 AM
Hi,
For my project, I'm using Lzdataset to get some information form the web. In fact, I'm calling a script on a webserver and this script returns me an xml file.
The lzx code looks like this:

----------------------------------------------
var ds = new LzDataset (this, {name:dsetName,
type: "http",
src: "http://j.arkos.free.fr/test6.php",
request: "true",
proxied: "false"});

ds.doRequest();
----------------------------------------------

Then, I'm using a solo deployment to generate a .swf file with the following url:
----------------------------------------------
http://localhost:8080/lps-3.0/examples/creatic/rss_autonome.lzx?lzproxied=false
----------------------------------------------

My problem begins here.
If I simply open the swf file with my web browser, it works perfectly. But if I launch it from the server, the connexion to my .php script doesn't seem to work and I receive no data.
Here is an exemple of an url that lead to the problem:

-----------------------------------------------
http://localhost:8080/lps-3.0/examples/creatic/rss_autonome39.lzx.swf
-----------------------------------------------

I don't understand why the script is not working. So if someone can help me, it will be really appreciate.

Thanks

altus34
09-27-2005, 07:40 AM
http://www.laszlosystems.com/developers/community/forums/showthread.php?threadid=4122

Arkos
09-28-2005, 01:30 PM
Thanks for the link. I find some useful information but I didn't get a true answer to my problem.
I make a lot of test but I couldn't suceed to make my swf file work on a webserver.
I try to execute my file on a website using apache Server and it just works fine. But when I use TomCat Server, it seems that the flashfile couldn't access the php script file describe in ły dataset.

Does anybody have an idea?
Thanks

bfagan
09-28-2005, 05:12 PM
Did you create a crossdomain.xml file on localhost that tells Flash it is allowed to read from j.arkos.free.fr?

Arkos
09-29-2005, 01:50 AM
Thanks for the information about crossdomain.xml.
I create this file and allow all access to make some test:

------------------------------
<?xml version="1.0"?>
<!DOCTYPE cross-domain-policy SYSTEM "http://www.macromedia.com/xml/dtds/cross-domain-policy.dtd">
<cross-domain-policy>
<allow-access-from domain="*" />
</cross-domain-policy>

------------------------------

But it still doesn't work. I'm using a TomCat Server but I don't really know where I must place the crossdomain file.

bfagan
09-29-2005, 06:01 AM
You need it in the server root:

http://localhost/crossdomain.xml

Are you uncertain where in the Tomcat path to put the file?

Arkos
09-29-2005, 07:10 AM
Yes, I wasn't sure about the location of the crossdomain file.
I test with the new location but the problem is still the same... The swf file cannot access my php script...