Tag Info

New answers tagged

0

Ok, As it's front-end... I might: Set up the folder on the server so that WordPress can read/write (775 or 755 ordinarily works depending on how your server is configured in terms of user/group permissions). Allow a user on the front end to see the files or choose which file to delete Upon choosing the file, pass the parameter to an intermediary PHP ...


0

I disabled the post thumbnail editor plugin, then everything started to work again as normal. But for the general advise for similar kind of issue is, disable your plugins one by one and test. Then you can find the plugin which is not compatible with wordpress update. So that you can disable that plugin at lease until it is giving new update. ...


0

I don't know of a plugin! Wordpress stores uploaded images in a media library which puts them in the posts table. As you have copied and pasted they are not in the media library, but just as img tags in the posts/pages themselves. Step 1 - copy the image files themselves, using an FTP to download them all then put them in ...


1

Found the problem. It was a problem with my host, in the path the ID3 folder name was uppercase, while on the server for some reason it was lowercase, this is why it didn't find it.


2

You should check for the special characters in url, sometimes url structures may contain special characters like space, &, ' . use str_repalce to replace known special characters or urlencode. media_sideload_image works properly with JPG as well so either url contains special characters. If you can access image through url there is not a permission ...


0

We used to be able to set the directory where files were kept and that option was removed so this might have something to do with the misdirected links. I had the same problem, but I went through and reuploaded the files that weren't working properly. This might not be realistic if you have lots of files but it is one option. Another option is to use a ...


0

Verify that the "GD" php library is enabled. You can do so by adding phpinfo(); to one of your php templates and then search the result for GD or GD Support. The GD library is used for image manipulation and resizing is one of those functions. To enable GD on windows you can edit the php.ini file in your php installation and uncomment the php_gd2.dll ...


1

This is a filter I use to keep my clients from adding special characters to their filenames, should work for you - you'll have to reupload the file though. /** /* Sanitize Uploaded Filenames /* @param array $file /* @return array $file */ function sanitize_file_uploads( $file ){ $file['name'] = sanitize_file_name($file['name']); $file['name'] = ...


0

Please include the following files before using media_sideload_image() for it to work, require_once(ABSPATH . 'wp-admin/includes/media.php'); require_once(ABSPATH . 'wp-admin/includes/file.php'); require_once(ABSPATH . 'wp-admin/includes/image.php'); Reference, WP Codex: media_sideload_image


1

I've had the same problem and found it was due to the upload file size set for the server (in my case 2mb). There is another setting which escapes me at this point, but is basically a limit on the amount of space that can be used to process uploaded images...which WordPress does when it re-sizes the images on upload. Unfortunately, unless you have root ...


0

I have no time to write at your code, but with your help works for me function wms_add_headerimage_cb( $post ){ //campuri $values = get_post_custom( $post->ID ); $headerpageimage = isset( $values['headerpageimage'][0] ) ? esc_attr( $values['headerpageimage'][0] ) : ''; $img_src = wp_get_attachment_image_src( $headerpageimage, ...


0

Show thumbnail preview instead of number Just as a tweak, I did this... changed the number input to hidden. added: $imgid =(isset( $instance[ 'imgid' ] )) ? $instance[ 'imgid' ] : ""; $img = wp_get_attachment_image_src($imgid, 'thumbnail'); And then... above the hidden field. if($img != "") { ?> <img src="<?= $img[0]; ?>" ...



Top 50 recent answers are included