all groups > macromedia flash flash remoting > april 2004 >
You're in the

macromedia flash flash remoting

group:

From localhost to live server...


From localhost to live server... intrepid_12
4/27/2004 9:59:31 AM
macromedia flash flash remoting:
Hi,
When I run my application on localhost, everything works fine. But when moving
to a live server I get: "Error opening URL .....".

I'm using server-side AS to send and retrieve data from my DB. I run
Coldfusion MX 6.1 on Apache 2.0.

Here's the code for the failed call:

#include "NetServices.as"
if (inited == null) {
inited = true;
NetServices.setDefaultGatewayUrl();
serviceConnection = NetServices.createGatewayConnection
("http://myDomain/web/flashservices/gateway");
serviceObject = serviceConnection.getService("address.persons3", this);
}

Here is the code for the working call:

#include "NetServices.as"
if (inited == null) {
inited = true;
var ass =
NetServices.setDefaultGatewayUrl("http://localhost/flashservices/gateway/");
serviceConnection = NetServices.createGatewayConnection(ass);
serviceObject = serviceConnection.getService("address.persons3", this);
}

Does the program bypass the URL when running on localhost since everything is
nice and sunny there? I'm getting pretty frustrated here...

I'm also wondering if 'flashservices/gateway' is required in the path?

Any help would be appreciated.
Re: From localhost to live server... intrepid_12
4/27/2004 11:55:05 AM
Found the error. One apperantly has to specify 'flashservices/gateway' in the
Flash-url, and can put the *.swf-file in flashservices/gateway subfolders when
running localhost.

However, when running on a public server this does not work. One still has to
specify flashservices/gateway in Flash, but you cannot put the *.swf-file in a
subfolder like: 'http://mydomain.no/flashservices/gateway'. I moved my project
to the root-folder and it worked...
Re: From localhost to live server... pstnotpd
4/27/2004 1:51:27 PM
Do you get an empty page when entering
http://myDomain/web/flashservices/gateway
in a browser? If the page is not found your gateway is not on there. Do
you have the correct portnumber?

Also if you embed the flash file in an HTML page the gatewayconnection
can be overridden from the embed tag

[quoted text, click to view]
Re: From localhost to live server... OHSAH
5/3/2004 7:48:53 PM
Do you mean inside
the /flashremoting/ folder?

Is that the only thing you have to do?
Are you using flash remoting trial version or do you have a production copy?
I just want to know if maybe this issue (in my case) is due to licensing
issues.
I just downloaded the flashremoting and based on the web site it should work
with full futures for 30 days.



Thanks


Alberto Ortega
OHSAH
Re: From localhost to live server... vrk17
5/10/2004 6:45:12 PM
[q][i]Originally posted by: [b][b]OHSAH[/b][/b][/i]
Do you mean inside
the /flashremoting/ folder?

Is that the only thing you have to do?
Are you using flash remoting trial version or do you have a production copy?
I just want to know if maybe this issue (in my case) is due to licensing
issues.
I just downloaded the flashremoting and based on the web site it should work
with full futures for 30 days.



Thanks


Alberto Ortega
OHSAH[/q]

Hi All,

I am also having same above mentioned problem. Everything works fine from my
local machine using 126.0.0.1 or localhost in
NetServices.setDefaultGatewayURL("http://127.0.0.1/ccaps/gateway.aspx") syntax;
but as soon as I replace localhost IP with the computer IP 192.168.1.110 (my
local computer network IP) it stops working also it doesn't display any error
in netConnection Debugger window. I tried to deploy my application on
developement server and trying to browse remotely, but it doesn't work. I am
using Flash MX and Flash Remoting Trial version. I doubt if Flash Remoting
trial version works only using 127.0.0.1 or localhost.

Thanks in advance,

Regards,

Vijay

Re: From localhost to live server... OHSAH
5/10/2004 6:51:52 PM
Hi there, this is what I did to overcome this issue.

whenever I need to make a connection to the server, I no longer use a
hardcoded reference to localhost, 127.0.0.1, etc.
Now I only parse the url of my movie to get the host (everything before
/flashremoting) with _root._url, and I use that to get my connection. This way,
the url used in the browser to load the movie, will always match the url to
open the connection.

Hope this helps


Alberto Ortega
OHSAH
Re: From localhost to live server... vrk17
5/10/2004 7:18:26 PM
Thanks OHSAH for your prompt reply.

My problem is flash remoting doesn't respond if I browse the application using
my computer IP or domain name. If I user localhost or 127.0.0.1 it works means
it works locally, but if I deploy my application on my development server
(public use) then it doesn't respond at all. I don't know why. May be it is
because I am using only trial version of Flash Remoting and may be trial
version works only with localhost or 127.0.0.1 IP.

Regards,

Vijay
Re: From localhost to live server... OHSAH
5/10/2004 7:54:53 PM
Actually trial version provides full functionality during first 30 days. After
that, it can only accept requests from localhost, as this seems to be your case.
Probably you will have to buy a new license or try in a different machine.

Alberto Ortega
OHSAH
Re: From localhost to live server... TheBimmer
3/7/2005 2:10:27 PM
Finnaly i found the solution for this problem guys,

all u have to do is to take the frconfig.txt file with u to where the dll is. (bin directory), and everything will work.

AddThis Social Bookmark Button