[ Index ]

WordPress 5.4.1

[ Index ]     [ Classes ]     [ Functions ]     [ Variables ]     [ Constants ]     [ Statistics ]    

title

Body

[close]

/wp-includes/ -> class-wp-matchesmapregex.php (summary)

WP_MatchesMapRegex helper class

File Size: 89 lines (2 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

WP_MatchesMapRegex:: (4 methods):
  __construct()
  apply()
  _map()
  callback()


Class: WP_MatchesMapRegex  - X-Ref

Helper class to remove the need to use eval to replace $matches[] in query strings.

__construct( $subject, $matches )   X-Ref
constructor

param: string $subject subject if regex
param: array  $matches data to use in map

apply( $subject, $matches )   X-Ref
Substitute substring matches in subject.

static helper function to ease use

param: string $subject subject
param: array  $matches data used for substitution
return: string

_map()   X-Ref
do the actual mapping

return: string

callback( $matches )   X-Ref
preg_replace_callback hook

param: array $matches preg_replace regexp matches
return: string



Generated: Tue May 19 15:51:04 2020 Cross-referenced by PHPXref 0.7.1