PDA

View Full Version : remoting works locally not on server


inclindwayne
10-06-2003, 05:06 PM
my flash remoting file work perfectly locally, but not when i upload the files to my server. what could cause this?

the movie is a simple textbox that pulls data from a SQL db, and scrools it across the screen.

if it helps the a.s. looks like this:

#include "NetServices.as"

if (inited == null) {
// do this code only once
inited = true;
// set the default gateway URL (this is used only in authoring)
NetServices.setDefaultGatewayUrl("http://www.irsd.net/flashservices/gateway");
// connect to the gateway
gateway_conn = NetServices.createGatewayConnection();
// get a reference to a service
newsService = gateway_conn.getService("http://www.irsd.net/components/news.cfc?wsdl", this);

newsService.getAnnouncements();

announcement_mc._x = 749;
}

function getAnnouncements_Result (result) {

var len = result.getLength();

if(len < 1)
{
announcement_mc.announce_txt.text = "Watch this scroll for important IRSD news...";
}

var obj = result.getItemAt(0).Title + " . . .";
for(var i = 1; i < len; i++)
{
obj = obj + " " + result.getItemAt(i).Title + " . . .";
}

with (announcement_mc.announce_txt) {
autoSize = "left";
text = obj;
}

}

if ((announcement_mc._x > 0) || (announcement_mc.announce_txt.maxhscroll == 0)){
announcement_mc._x -= 1;
}

if ((announcement_mc.announce_txt.hscroll == announcement_mc.announce_txt.maxhscroll) && (announcement_mc.announce_txt.maxhscroll != 0)) {
announcement_mc._x -= 1;
}

if ((announcement_mc._x == 0) && (announcement_mc.announce_txt.maxhscroll != 0)) {
announcement_mc.announce_txt.hscroll += 1;
}

if (announcement_mc._x < (announcement_mc.announce_txt._width * -1)) {
announcement_mc._x = 749;
announcement_mc.announce_txt.hscroll = 0;
}

freddycodes
10-06-2003, 05:42 PM
Is this with Flash MX or MX 2004?

With MX is it possible that the cfc is not located in the same domain as the swf calling it? In MX it must be.

inclindwayne
10-07-2003, 02:29 PM
i fixed it, thanks., check it out working at www.irsd.net if your bored.

skagen
10-08-2003, 03:29 AM
How did you fix the problem? I'm having the same issue.