]> git.mxchange.org Git - friendica-addons.git/blobdiff - xmpp/xmpp.php
Update function calls
[friendica-addons.git] / xmpp / xmpp.php
index e589f9229706e21e80ea1ce63d19c25200b58118..d80abb64cf1e7309adaf23c7414adc8facfb57cb 100644 (file)
@@ -11,6 +11,7 @@ use Friendica\Core\Addon;
 use Friendica\Core\Config;
 use Friendica\Core\L10n;
 use Friendica\Core\PConfig;
+use Friendica\Core\Renderer;
 
 function xmpp_install()
 {
@@ -49,7 +50,7 @@ function xmpp_addon_settings(App $a, &$s)
 
        /* Add our stylesheet to the xmpp so we can make our settings look nice */
 
-       $a->page['htmlhead'] .= '<link rel="stylesheet"  type="text/css" href="' . $a->get_baseurl() . '/addon/xmpp/xmpp.css' . '" media="all" />' . "\r\n";
+       $a->page['htmlhead'] .= '<link rel="stylesheet"  type="text/css" href="' . $a->getBaseURL() . '/addon/xmpp/xmpp.css' . '" media="all" />' . "\r\n";
 
        /* Get the current state of our config variable */
 
@@ -104,9 +105,9 @@ function xmpp_login()
 
 function xmpp_addon_admin(App $a, &$o)
 {
-       $t = get_markup_template('admin.tpl', 'addon/xmpp/');
+       $t = Renderer::getMarkupTemplate('admin.tpl', 'addon/xmpp/');
 
-       $o = replace_macros($t, [
+       $o = Renderer::replaceMacros($t, [
                '$submit' => L10n::t('Save Settings'),
                '$bosh_proxy' => ['bosh_proxy', L10n::t('Jabber BOSH host'), Config::get('xmpp', 'bosh_proxy'), ''],
                '$central_userbase' => ['central_userbase', L10n::t('Use central userbase'), Config::get('xmpp', 'central_userbase'), L10n::t('If enabled, users will automatically login to an ejabberd server that has to be installed on this machine with synchronized credentials via the "auth_ejabberd.php" script.')],
@@ -164,7 +165,7 @@ function xmpp_converse(App $a)
                        PConfig::set(local_user(), "xmpp", "password", $password);
                }
 
-               $jid = $a->user["nickname"] . "@" . $a->get_hostname() . "/converse-" . random_string(5);
+               $jid = $a->user["nickname"] . "@" . $a->getHostName() . "/converse-" . random_string(5);
 
                $auto_login = "auto_login: true,
                        authentication: 'login',