taking two values from an array and passing them as variables to a function
<p>How can I pass specifically the number of 2 values from an array into a function then loop over the array and take the next 2 values from the array.</p>

<p>For example</p>

<pre><code>&lt;?php
    $fileArray Array("file1", "file2", "file3", "file4", "file5", "file6", "file7", "file8", "file9", "file10")

    function fileFunction($file1, $file2)
    {
     $dostuffhere;
    }

    [loop]
    fileFunction($fileArray[$key], $fileArray[$key]);
    [/loop]
?&gt;
</code></pre>

<p><em>Note</em> that the <code>$fileArray</code> can and will be longer than 10 items.</p>
