How To Change WordPress Attachment Page Image Size?

How To Change WordPress Attachment Page Image Size
Medium size is the default value of attachment page image size in WordPress. Medium size images perfectly matched for some themes only. Most of the themes need full size or large size images in attachment page because these values only fixed for the themes width. let checkout how to the WordPress attachment page image size.

For change the image size you don’t need to edit the theme files. You need to edit a “post-template.php” file from “wp-includes” directory. Never forget this file will be rewritten after updating the WordPress sometimes. So you need edit this file again if the attachment page image size changed to default value after the WordPress update.

Step 1 : Edit  “post-template.php” file from “wp-includes” folder

Step 2 : Find this code wp_get_attachment_link(0, ‘medium’

Step 3 : Change the default value medium to full or large

Step 4 : Click save or update to save this changes. Attachment page image size will be changed immediately once you have done this update.