Alright, based on the code in How to insert console.log(res) data to database using php mysqli, this is the problem:
- It only gets the attendees list directly when you join from the web sdk.
Solution:
- You need to add a button to your HTML, and then move your
getAttendeeslist()
call into a separatedonClick
event listener function for that button.
That way you can click the button at any time, and thereby get the attendees list any time you want.
Steps:
- Add this to your HTML file
<button type="button" id="get_attendees_list_btn">List attendees</button>
- Put this code in your JavaScript file. It could go at the root of the file, or inside the
ZoomMtg.join()
success handler. It doesn’t really matter.
document.getElementById("get_attendees_list_btn").onclick = function () {
ZoomMtg.getAttendeeslist(/* ... */)
}