If using MIN_STREAMING_PORT then use ['SERVER_NAME'] instead of HTTP_HOST because HTTP_HOST may contain a custom port

This commit is contained in:
Isaac Connor committed 2018-04-04 16:45:25 -04:00
1 parent 489f11bd07
commit 6ebedff2e1
1 file changed
+2 -2
+2 -2
View File
@@ -199,11 +199,11 @@ private $control_fields = array(
if ( isset($this->{'ServerId'}) and $this->{'ServerId'} ) {
$Server = new Server( $this->{'ServerId'} );
$streamSrc .= $Server->Hostname();
} else if ( ZM_MIN_STREAMING_PORT )
$streamSrc .= $_SERVER['SERVER_NAME'].':'.(ZM_MIN_STREAMING_PORT+$this->{'Id'});
} else {
$streamSrc .= $_SERVER['HTTP_HOST'];
}
if ( ZM_MIN_STREAMING_PORT )
$streamSrc .= ':'. (ZM_MIN_STREAMING_PORT+$this->{'Id'});
$streamSrc .= ZM_PATH_ZMS;
$args['monitor'] = $this->{'Id'};