2018-01-28, 02:40 AM
(2018-01-28, 02:35 AM)RateU Wrote: You can try to join users table with userfields table inside a query so you can filter the results based on usergroup and profile fields value. Store the results inside an array. shuffle it. Do an iteration after it is shuffled. Inside the iteration, use the API to check the user. If he/she is "Live", then break. Output the result.
Yea Right now I'm just basing it off of me and one other person. I have it checking the user group and it is working. I need to join in the ability to search non empty profile field. I also have it picking a random number between 0 (first index of an array) and the count of the array of users to promote - 1 so it does not get an empty field.
Though now my problem is the variable {$streamer} is being displayed above the header of the portal and I have no idea where or how that is happening...