This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Get attachment file type extension | |
* | |
* Requires that you have the attachment id | |
* See this post http://jeremyjaymes.com/display-attach…ordpress-theme/ for more explanation | |
*/ | |
//* Assumes we're in a loop and have our attachment id already | |
$file_url = wp_get_attachment_url( $file_id ); |
OlderNewer