Php Basename

/ Comments off

Gets the basename of a plugin.

Arrays in PHP is a type of data structure that allows us to store multiple elements of similar data type under a single variable thereby saving us the effort of creating a different variable for every data. Basename is locale aware, so for it to see the correct basename with multibyte character paths, the matching locale must be set using the setlocale function. If path contains characters which are invalid for the current locale, the behavior of basename is undefined. Hiding PHP Keeping Current Features HTTP authentication with PHP Cookies Sessions Dealing with XForms Handling file uploads Using remote files Connection handling Persistent Database Connections Command line usage Garbage Collection DTrace Dynamic Tracing Function Reference Affecting PHP's Behaviour Audio Formats Manipulation Authentication.



  • Related

Description Description

Php Basename Function

This method extracts the name of a plugin from its filename.

Parameters Parameters

Php basename()

(string)(Required)The filename of plugin.

Return Return

(string) The name of a plugin.

Php Basename Function

More Information More Information

This function gets the path to a plugin file or directory, relative to the plugins directory, without the leading and trailing slashes.
Uses both the WP_PLUGIN_DIR and WPMU_PLUGIN_DIR constants internally, to test for and strip the plugins directory path from the $file path. Note that the direct usage of WordPress internal constants is not recommended.

Source Source

File: wp-includes/plugin.php Unity visual studio code not autocomplete.

View on Trac

Php Get File Name

Related Related

Php Basename Filename

Uses Uses

Php Basename()


Normalize a filesystem path.