Changeset 58286 for trunk/src/wp-includes/rest-api.php
- Timestamp:
- 06/02/2024 10:00:26 PM (11 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/rest-api.php
r58267 r58286 1008 1008 1009 1009 if ( $resource ) { 1010 printf( '<link rel="alternate" type="application/json" href="%s" />', esc_url( rest_url( $resource ) ) ); 1010 printf( 1011 '<link rel="alternate" title="%1$s" type="application/json" href="%2$s" />', 1012 _x( 'JSON', 'REST API resource link name' ), 1013 esc_url( rest_url( $resource ) ) 1014 ); 1011 1015 } 1012 1016 } … … 1033 1037 1034 1038 if ( $resource ) { 1035 header( sprintf( 'Link: <%s>; rel="alternate"; type="application/json"', sanitize_url( rest_url( $resource ) ) ), false ); 1039 header( 1040 sprintf( 1041 'Link: <%1$s>; rel="alternate"; title="%2$s"; type="application/json"', 1042 sanitize_url( rest_url( $resource ) ), 1043 _x( 'JSON', 'REST API resource link name' ) 1044 ), 1045 false 1046 ); 1036 1047 } 1037 1048 }
Note: See TracChangeset
for help on using the changeset viewer.