Randomly get an existing movie id

Post here any issues with the API or feature requests
Post Reply
visualcookie
Posts: 1
Joined: Thu Nov 10, 2016 11:00 pm

Randomly get an existing movie id

Post by visualcookie »

Hi,

I'm currently trying to randomly get an existing movie id to get it's moviebackground. At the moment I just have an array list with movie ids... but this case is such a waste of time. Current code looks like this:

Code: Select all

// Get random movieID
$movieIDs = [59859,140607,2501,49040,2502,2503,20526,672,12445,674,675,673,313297,177572,105,165,196,297761,268,272,414,142061,75656,291805];
$movieID = $movieIDs[array_rand($movieIDs)];
Is there another approach on how to get this done more efficently?
Post Reply