wp_generate_attachment_metadata( ... )

Generate attachment meta data and create image sub-sizes for images.

Parameters:
  • $attachment_id int
  • $file string