← All docs

mb_ereg_search_init()

Initializes the retained multibyte regex subject and optionally compiles a search pattern.

mb_ereg_search_init()

function mb_ereg_search_init(string $string, ?string $pattern = null, ?string $options = null): bool

Initializes the retained multibyte regex subject and optionally compiles a search pattern.

Parameters:

  • $string (string)
  • $pattern (?string), default null, optional
  • $options (?string), default null, optional

Returns: bool

Availability

No examples yet. Check examples/ and showcases/ for usage patterns.

Internals

For how mb_ereg_search_init is implemented in the compiler, see the internals page.