get_the_archive_title_prefix
Filter HookDescription
Filters the archive title prefix.Hook Information
File Location |
wp-includes/general-template.php
View on GitHub
|
Hook Type | Filter |
Line Number | 1783 |
Hook Parameters
Type | Name | Description |
---|---|---|
string
|
$prefix
|
Archive title prefix. |
Usage Examples
Basic Usage
<?php
// Hook into get_the_archive_title_prefix
add_filter('get_the_archive_title_prefix', 'my_custom_filter', 10, 1);
function my_custom_filter($prefix) {
// Your custom filtering logic here
return $prefix;
}
Source Code Context
wp-includes/general-template.php:1783
- How this hook is used in WordPress core
<?php
1778 *
1779 * @since 5.5.0
1780 *
1781 * @param string $prefix Archive title prefix.
1782 */
1783 $prefix = apply_filters( 'get_the_archive_title_prefix', $prefix );
1784 if ( $prefix ) {
1785 $title = sprintf(
1786 /* translators: 1: Title prefix. 2: Title. */
1787 _x( '%1$s %2$s', 'archive title' ),
1788 $prefix,
PHP Documentation
<?php
/**
* Filters the archive title prefix.
*
* @since 5.5.0
*
* @param string $prefix Archive title prefix.
*/
Quick Info
- Hook Type: Filter
- Parameters: 1
- File: wp-includes/general-template.php
Related Hooks
Related hooks will be displayed here in future updates.