WPDev.one
Core Function
View Source on Trac ↗

wp_upload_bits()

wp_upload_bits( mixed $name, mixed $deprecated, mixed $bits, mixed $time = null )

Creates a file in the upload folder with given content.

Parameters 4 required

Name / Type Description
$name
string

Filename.

Required
(null

| string) $deprecated Never used. Set to null.

Required
$bits
string

File content

Required
(string

| null) $time Optional. Time formatted in 'yyyy/mm'. Default null.

Required

Return Value

(array)
array { Information about the newly-uploaded file.

Function Information

Since Version
2.0.0
Source File
wp-includes/functions.php
Advertisement