Use of showInviteFunction

Sorry I’m trying to figure out how to hide the invite button.
I understand that it should be used:

ZoomMtg.showInviteFunction({
show: true
});

but how do you use it?

    ZoomMtg.showInviteFunction({
        show: false
    });

    ZoomMtg.init({
        leaveUrl: 'http://www.zoom.us',
        isSupportAV: true,
        success: function () {
            ZoomMtg.join(
                    {
                        meetingNumber: meetConfig.meetingNumber,
                        userName: meetConfig.userName,
                        signature: signature,
                        apiKey: meetConfig.apiKey,
                        userEmail: '',
                        passWord: meetConfig.passWord,
                        success: function (res) {
                            $('#nav-tool').hide();
                            console.log('join meeting success');
                        },
                        error: function (res) {
                            console.log(res);
                        }
                    }
            );
        },
        error: function (res) {
            console.log(res);
        }
    });

in this way the button is always present. isn’t this the way?
thank you so much
Giuseppe

Hey @zoom11 (Giuseppe)!

If you want to DISABLE the Invite function, a parameter disableInvite is a boolean flag you can use while creating the meeting [ZoomMtg.init](https://zoom.github.io/sample-app-web/ZoomMtg.html#init) as documented in the WebSDK Reference

ZoomMtg.init({
    debug: true, //optional
    leaveUrl: 'http://www.zoom.us', //required
    showMeetingHeader: false, //option
    **disableInvite: false, //default is false (enable), parameter is optional**
    disableCallOut: false, //optional
    disableRecord: false, //optional
    disableJoinAudio: false, //optional
    audioPanelAlwaysOpen: true, //optional
    showPureSharingContent: false, //optional
    isSupportAV: true, //optional,
    isSupportChat: true, //optional,
    isSupportQA: true, //optional,
    isSupportCC: true, //optional,
    screenShare: true, //optional,
    rwcBackup: '', //optional,
    videoDrag: true, //optional,
    sharingMode: 'both', //optional,
    videoHeader: true, //optional,
    isLockBottom: true, // optional,
    isSupportNonverbal: true, // optional,
    isShowJoiningErrorDialog: true // optional
    });

You also referenced in your post, the [ZoomMtg.showInviteFunction()](https://zoom.github.io/sample-app-web/ZoomMtg.html#showInviteFunction). This method of the WebSDK is used to toggle visibility of the Invite function, but is NOT the same as disabling the invite function as I described earlier.

If your goal is to 100% HIDE / DISABLE the Invite function:

  1. When creating the meeting make sure to set disableInvite: true in the configuration object parameter you pass into ZoomMtg.init()

  2. In the callback when the meeting has been created, make a call to ZoomMtg.showInviteFunction({show: false}) to HIDE the Invite function.

The ZoomMtg.showInviteFunction() is used AFTER a meeting has been created, and can be triggered/called by your web app as you see fit to make available (UI, data change, special event, etc…)

Does this help answer your question?

of course I solved thanks to you!!!

Giuseppe

2 Likes

Thanks @bdeanindy! :slight_smile:

-Tommy

1 Like