Question
Can't connect to server remotely, connects fine locally
I've got an extremely frustrating problem that I can't figure
out. I have a simple application to test the connection to the FMS
2 server. If it can connect it basically just says "Connection
Successful", if it can't connect "Connection Failed". It's named
'FMStest' and I have created a folder by that name in the
'applications' directory within the FMS2 directory. The local
version connects successfully and shows as connected in the
management console--the connection string I'm using locally is:
rtmpNow = "rtmp:/FMStest";
The remote connection fails everytime--I upload the published files to our webserver and access the created html file. the connection string I use for the remote connection is:
rtmpNow = "rtmp://my.domain.com/FMStest"; //domain changed for security reasons
Here is the full code:
var nc:NetConnection = new NetConnection();
var rtmpNow:String = new String();
rtmpNow = "rtmp://my.domain.com/FMStest"; //changed for privacy
nc.onStatus = function(info){
trace ("Level: "+info.level+" Code: "+info.code);
trace(code.list);
connect_txt.text = info.code;
if(connect_txt.text == "NetConnection.Connect.Failed"){
stat_text.text="Status: Not Connected";
status_text.text = "Connection to "+rtmpNow+" failed"+" Level: "+info.level+" Code: "+info.code;
}
else{
status_text.text = "connection successful";
stat_text.text="Status: Connected!";
}
};
nc.connect(rtmpNow);
stat_text.text = "Status: Connecting";
////////////////////////////////////////////////////////////
We've checked all the firewall and other configurations, I've tried all variations of the connection string (including using the IP address) No luck. Any ideas?
rtmpNow = "rtmp:/FMStest";
The remote connection fails everytime--I upload the published files to our webserver and access the created html file. the connection string I use for the remote connection is:
rtmpNow = "rtmp://my.domain.com/FMStest"; //domain changed for security reasons
Here is the full code:
var nc:NetConnection = new NetConnection();
var rtmpNow:String = new String();
rtmpNow = "rtmp://my.domain.com/FMStest"; //changed for privacy
nc.onStatus = function(info){
trace ("Level: "+info.level+" Code: "+info.code);
trace(code.list);
connect_txt.text = info.code;
if(connect_txt.text == "NetConnection.Connect.Failed"){
stat_text.text="Status: Not Connected";
status_text.text = "Connection to "+rtmpNow+" failed"+" Level: "+info.level+" Code: "+info.code;
}
else{
status_text.text = "connection successful";
stat_text.text="Status: Connected!";
}
};
nc.connect(rtmpNow);
stat_text.text = "Status: Connecting";
////////////////////////////////////////////////////////////
We've checked all the firewall and other configurations, I've tried all variations of the connection string (including using the IP address) No luck. Any ideas?