Comment on page
4
Methods & Options
You can customize the plugin by passing configurations
To set configuration through javascript, use
set
method.SocialInviter.set({
modal: false,
header: false,
style: {
'font-family': 'Arial'
}
});
To show plugin through custom javascript code, use
show
method.SocialInviter.show();
To hide plugin
SocialInviter.hide();
To show the plugin on the page inline (not in a modal window), use a div that should have a class
socialinviter
and use set
method.<div style="height:500px">
<div class="socialinviter"></div>
</div>
SocialInviter.set({
modal: false,
header: false
});
To add a secondary authentication URL without removing the primary authentication URL, use
authUrl
. This will be helpful when you are locally doing debugging or testing the product in stage/testing servers.SocialInviter.set({
authUrl: {
development: 'http://127.0.0.1:5501/oauth.html',
stage: 'https://stage.yourdomain.com/oauth.html',
},
modal: false,
header: false
});
To open the import service for a particular service, use
auth
method.SocialInviter.auth('google');
To go a specific screen
SocialInviter.goToScreen('thankyou');
To show loading, pass the text
SocialInviter.showLoading('Loading...');
To hide loading
SocialInviter.hideLoading();
To get logged in user profile
SocialInviter.getProfile();
To get the currently selected service
SocialInviter.getService();
To get all imported contacts
SocialInviter.getAllContacts();
To get all selected contacts
SocialInviter.getAllSelected();
To get all selected contacts and the manually entered contacts
SocialInviter.getAllSelectedRecipients();