authorise('core.create', 'com_weblinks') || $user->authorise('core.edit', 'com_weblinks') || $user->authorise('core.edit.own', 'com_weblinks')) { // The URL for the weblinks list $link = 'index.php?option=com_weblinks&view=weblinks&layout=modal&tmpl=component&' . JSession::getFormToken() . '=1&editor=' . $name; $button = new JObject; $button->modal = true; $button->class = 'btn'; $button->link = $link; $button->text = JText::_('PLG_EDITORS-XTD_WEBLINK_BUTTON_WEBLINK'); $button->name = 'link'; $button->options = "{handler: 'iframe', size: {x: 800, y: 500}}"; return $button; } } }