Skip to content

Commit

Permalink
Added basic DB for song entries.
Browse files Browse the repository at this point in the history
  • Loading branch information
Kevin McDonagh committed Sep 5, 2010
1 parent 300ed96 commit a9d8205
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 12 deletions.
22 changes: 10 additions & 12 deletions code/mashbox1.php
Original file line number Diff line number Diff line change
Expand Up @@ -67,18 +67,16 @@
</tr>
</thead>
<tbody>
<tr>
<td><span>Wu Tang</span> <b>+</b> <span>Fisher Band</span></td>
<td><span>Kevin</span> <b>&amp;</b> <span>Yves</span></td>
</tr>
<tr>
<td><span>Wu Tang</span> <b>+</b> <span>Fisher Band</span></td>
<td><span>Kevin</span> <b>&amp;</b> <span>Yves</span></td>
</tr>
<tr>
<td><span>Wu Tang</span> <b>+</b> <span>Fisher Band</span></td>
<td><span>Kevin</span> <b>&amp;</b> <span>Yves</span></td>
</tr>
<?php
$dbh = new PDO('sqlite:mashbox2.sqlite');
foreach($dbh->query('SELECT * FROM tracks') as $row){
echo ("<tr>\n");
echo ("<td><span>" . $row['title'] . "</span> <b>+</b> <span>" . $row['artist'] . "</span></td>\n");
echo ("<td><span>". $row['addedby1'] . "</span> <b>&amp;</b> <span>". $row['addedby2'] . "</span></td>\n");
echo ("<tr>\n");
}
$dbh = null;
?>
</tbody>
</table>
</div>
Expand Down
Binary file added code/mashbox2.sqlite
Binary file not shown.

0 comments on commit a9d8205

Please sign in to comment.