Media upload error

I found the solution. Rename your function.php file. Now it works fine for other themes. In my theme exactly the problem lies between the style tag. remove style tags and then check your admin panel. Thanks.

How to get attached image alt text in media.php?

In the answers to this forum post is mentioned that $alt = get_post_meta($attachment_id, ‘_wp_attachment_image_alt’, true); will get the job done for you. Maybe you should give that a try and look at the further information there.

If image width bigger than height [duplicate]

Use wp_get_attachment_metadata(). Using your example: $img_data = wp_get_attachment_metadata( $attachment_id ); $w = $img_data[‘width’]; $h = $img_data[‘height’]; if ($w > $h) { $class = “col-sm-12”; } else { $class = “col-sm-6”; } Though, to get the attachment ID, you’ll either have to put a filter that acts on every image or create a loop that uses … Read more

While doing a bulk upload the Media Images are showing blank?

Your $loopimage field in your spreadsheet only has the filename and not the file path, but wp_insert_attachment needs the full pathname in the 2nd argument. Additionally though, if you have uploaded all of these images using the Media Manager interface then they will already be stored as attachments. You’d be better off using the file … Read more

Parallax image problem

Doesn’t sound like you’re doing anything wrong but can’t really assist without more information. I’m thinking it’s either a theme, plugin, or server issue. First try disabling the cherry lazy load / parallax plugins to see if it is coming from there. Then try changing your theme to see if you have the same problem … Read more

How to hide image alt text/caption in Visual Composer?

i had also the same issue when using the AVADA theme. It appends the title attribute on the image which is showing the text/caption when its being on hover. <script type=”text/javascript”> /* The first line waits until the page has finished to load and is ready to manipulate */ $(document).ready(function(){ /* remove the ‘title’ attribute … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)