File size not being displayed in attachment.php
-
The filesize for pages are ok, they are displayed. The problem arises when the attachment.php is loaded. There’s a if that checks is the attachment is an image and if it’s not it shows only the link for file as follows:
<a href="<?php echo wp_get_attachment_url($post->ID) ?>" title="<?php echo esc_html(get_the_title($post->ID)) ?>" rel="attachment"><?php echo basename($post->guid);?></a>
It happens that in this case the file size is not displayed. What could be wrong in this code?
Thanks in advance.https://www.ads-software.com/extend/plugins/mimetypes-link-icons/
Viewing 7 replies - 1 through 7 (of 7 total)
Viewing 7 replies - 1 through 7 (of 7 total)
- The topic ‘File size not being displayed in attachment.php’ is closed to new replies.