WordPress: How to get attachment file size by id?

How to get attachment file size by id? @wordpress
$attachment_id = 100; // attachment id
$file_size = filesize ( get_attached_file( $attachment_id ) ); 

Share this post:

Share on facebook
Share on twitter
Share on linkedin
Share on email
Amitpal Singh
Amitpal Singh
Freelance website and application developer. Working from Sangrur Punjab in India.
Follow Amitpal on:

Register

Create your account and post ad