I\'m a php noob and I just made a little script from some other scripts I found on the net. It picks 3 random images from a folder named \"Random\" and shows them.
While
If your only problem is the undefined variable, it's easy.
The server settings are different on your local and remote servers so one returns the error and the other doesn't, but when you ask !$random2 before it exists it will return an error.
So simply set $random2 to false before the while loop.
The same goes for $random3.