PHP implode array with prefix and commar seperated
<p>I am trying to build an sql query using an array and add a prefix. </p>

<p>E.g: </p>

<pre><code>$columns = array('column1', 'column2');

"SELECT ". ltrim(implode(", media_", $columns), ', ') . " FROM media WHERE media_id = '{$id}'";
</code></pre>

<p>Outputs:</p>

<blockquote>
  <p>SELECT filename, media_image FROM media WHERE media_id = '3'</p>
</blockquote>

<p>What I really want:</p>

<blockquote>
  <p>SELECT media_column1, media_column2 FROM media WHERE media_id =
  '3'</p>
</blockquote>

<p>Question: How can I:
1. Prefix all items of the array with "media_"
2. Separate more than 1 item with a comma?</p>
