 <p>Store the tile in the array and print it - </p> <pre><code>&lt;?php $video_array = array( array('url' =&gt; 'http://www.youtube.com/embed/rMNNDINCFHg', 'title' =&gt; 'ABC'), array('url' =&gt; 'http://www.youtube.com/embed/bDF6DVzKFFg', 'title' =&gt; 'DSF'), array('url' =&gt; 'http://www.youtube.com/embed/bDF6DVzKFFg', 'title' =&gt; 'RYUY') ); shuffle($video_array); $video = $video_array[0]; ?&gt; &lt;iframe width='1006' height='421' src='&lt;?php echo $video['url']; ?&gt;' title='&lt;?php echo $video['title']; ?&gt;' frameborder='0' allowfullscreen&gt;&lt;/iframe&gt; </code></pre>