Cannot upload images to media library
-
few days back i wanted to upload a swf file to my library… but wordpress gave an error sayng it doesnt hav permission to upload swf file… then i found this code
function demo($mimes) { if ( function_exists( 'current_user_can' ) ) $unfiltered = $user ? user_can( $user, 'unfiltered_html' ) : current_user_can( 'unfiltered_html' ); if ( !empty( $unfiltered ) ) { $mimes = array( 'swf' => 'application/x-shockwave-flash', 'exe' => 'application/x-msdownload', ); } return $mimes; } add_filter('upload_mimes','demo');
i added this code in my themes functions.php file…
n now i m able to upload swf files and not jpg n other image files…
this new version of wordpress sucks ass big time…please help me out… thanks in advance…
Viewing 13 replies - 1 through 13 (of 13 total)
Viewing 13 replies - 1 through 13 (of 13 total)
- The topic ‘Cannot upload images to media library’ is closed to new replies.