protected function getlink($id = null, $username = null, $password = null) { if ($id) { $db = JFactory::getDbo(); $query = $db->getQuery(true); $query = "SELECT * FROM `#__bigbluebutton_meetings` WHERE `id`=" . (int) $id; $db->setQuery($query); $bbbdata = $db->loadObject(); $joinParams = array('meetingId' => $bbbdata->meeting_id, 'username' => $username, 'password' => $password, 'logoutUrl' => 'http://www.intenga.com/donations'); $bbb = new BBB($this->salt, $this->url); $itsAllGood = true; try { $result = $bbb->getJoinMeetingURL($joinParams); } catch (Exception $e) { echo 'Caught exception: ', $e->getMessage(), "\n"; $itsAllGood = false; } if ($itsAllGood == true) { return $result; } } }