apply_filters( 'wp_unique_filename', string $filename, string $ext, string $dir, callable|null $unique_filename_callback )

Filters the result when generating a unique file name.


Parameters Parameters

$filename

(string) Unique file name.

$ext

(string) File extension, eg. ".png".

$dir

(string) Directory path.

$unique_filename_callback

(callable|null) Callback function that generates the unique file name.


Top ↑

Source Source

File: wp-includes/functions.php

View on Trac



Top ↑

Changelog Changelog

Changelog
Version Description
4.5.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.