wp_handle_upload

Advertisement

Summery Summery

Filters the data array for the uploaded file.

Syntax Syntax

apply_filters( 'wp_handle_upload', array $upload, string $context )

Parameters Parameters

$upload

(array) Array of upload data.

  • 'file'
    (string) Filename of the newly-uploaded file.
  • 'url'
    (string) URL of the newly-uploaded file.
  • 'type'
    (string) Mime type of the newly-uploaded file.

$context

(string) The type of upload action. Values include 'upload' or 'sideload'.

Source Source

File: wp-admin/includes/file.php

Advertisement

Changelog Changelog

Changelog
Version Description
2.1.0 Introduced.

Advertisement

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.