get_edit_comment_link
Filters the comment edit link.
Description
Parameters (1)
- 0. $location (string)
- The edit link.
Usage
- To run the hook, copy the example below.
- $location = apply_filters( 'get_edit_comment_link', $location );
- if ( !empty( $location ) ) {
- // everything has led up to this point...
- }
- The following example is for adding a hook callback.
- // define the get_edit_comment_link callback
- function filter_get_edit_comment_link( $location ) {
- // make filter magic happen here...
- return $location;
- };
- // add the filter
- add_filter( 'get_edit_comment_link', 'filter_get_edit_comment_link', 10, 1 );
- To remove a hook callback, use the example below.
- // remove the filter
- remove_filter( 'get_edit_comment_link', 'filter_get_edit_comment_link', 10, 1 );
Defined (1)
The filter is defined in the following location(s).
- /wp-includes/link-template.php
- return apply_filters( 'get_edit_comment_link', $location );