Puoi usare un qualsiasi ciclo.

Nel manuale ufficiale trovi molti esempi esaustivi:

http://www.php.net/foreach