I have a table called 'filename'. I try to output <a> tags in a loop from it like this:
<?php
while($sermon = mysql_fetch_assoc($sermonsQ)) {
echo '<a href="admin/'. $sermon ['filename'] . '">';
echo 'download</a></td>';
}
Current problem is, that $sermon['filename'] containts a leading path like path/test.mp3. But I need only the filename without the path, like test.mp3. How can I do this?