_get_template_edit_filename()
Tidies a filename for url display by the theme file editor.
Internal function — this function is designed to be used by the kernel itself. It is not recommended to use this function in your code.
No Hooks.
Return
String
.
Usage
_get_template_edit_filename( $fullpath, $containingfolder );
- $fullpath(string) (required)
- Full path to the theme file
- $containingfolder(string) (required)
- Path of the theme parent folder
Changelog
Since 2.9.0 | Introduced. |
_get_template_edit_filename() get template edit filename code WP 6.7.1
function _get_template_edit_filename( $fullpath, $containingfolder ) { return str_replace( dirname( $containingfolder, 2 ), '', $fullpath ); }