Code conventions and URL update in OpenMeetings plugin - refs BT#7046 refs #5491

1.9.x
Yannick Warnier 12 years ago
parent bd392b59df
commit 527616544e
  1. 12
      plugin/openmeetings/lib/openmeetings_gateway.php

@ -32,9 +32,14 @@ class OpenMeetingsGateway
public $session_id = ""; public $session_id = "";
public $config; public $config;
function __construct($cfg) function __construct()
{ {
$this->config = $cfg; $this->_user = CONFIG_OPENMEETINGS_USER;
$this->_pass = CONFIG_OPENMEETINGS_PASS;
$this->_url = CONFIG_OPENMEETINGS_SERVER_URL;
if (substr($this->_url, -1, 1) == '/') {
$this->_url = substr($this->_url, 0, -1);
}
} }
function getRestUrl($name) function getRestUrl($name)
@ -45,8 +50,7 @@ class OpenMeetingsGateway
function getUrl() function getUrl()
{ {
// FIXME protocol should be added // FIXME protocol should be added
$port = $this->config["port"] == 80 ? '' : ":" . $this->config["port"]; return $this->_url;
return $this->config["protocol"] . "://" . $this->config["host"] . $port . "/" . $this->config["webappname"];
} }
function var_to_str($in) function var_to_str($in)

Loading…
Cancel
Save