class.upload.php is a powerful and mature PHP class to manage uploaded files, and manipulate images in many ways. The script is available under a GPL license.
Can you refer me to your development listings of mime-types?
I'm writing if statements to embed a image extensions (like wordpress media library icons) and I can't find audio/x-ms-wma @ w3schools. I don't want to miss anything but it's not really a major problem because if ever I missed one mime-type, it prints the default blank icon.
Can you refer me to your development listings of mime-types?
I'm writing if statements to embed a image extensions (like wordpress media library icons) and I can't find audio/x-ms-wma @ w3schools. I don't want to miss anything but it's not really a major problem because if ever I missed one mime-type, it prints the default blank icon.
// Credits http://www.w3schools.com/media/media_mimeref.asp if ( ( $media->media_filetype == 'image/jpeg' ) || ( $media->media_filetype == 'image/bmp' ) || ( $media->media_filetype == 'image/gif' ) || ( $media->media_filetype == 'image/pipeg' ) || ( $media->media_filetype == 'image/png' ) || ( $media->media_filetype == 'image/tiff' ) || ( $media->media_filetype == 'image/xbitmap' ) || ( $media->media_filetype == 'image/x-ms-bmp' ) || ( $media->media_filetype == 'image/icon' ) ) { $PSOUP_tpl->assign_vars(array( 'media.IMAGE' => '../' . $PSOUP_CONTENT_DIR['Images'] . 'mime-types/image.png', )); } elseif ( ( $media->media_filetype == 'audio/basic' ) || ( $media->media_filetype == 'audio/mid' ) || ( $media->media_filetype == 'audio/mpeg' ) || ( $media->media_filetype == 'audio/x-aiff' ) || ( $media->media_filetype == 'audio/x-mpegurl' ) || ( $media->media_filetype == 'audio/x-pn-realaudio' ) || ( $media->media_filetype == 'audio/wav' ) || ( $media->media_filetype == 'audio/x-ms-wma' ) ) { $PSOUP_tpl->assign_vars(array( 'media.IMAGE' => '../' . $PSOUP_CONTENT_DIR['Images'] . 'mime-types/audio.png', )); } else { $PSOUP_tpl->assign_vars(array( 'media.IMAGE' => '../' . $PSOUP_CONTENT_DIR['Images'] . 'mime-types/empty.png', )); }