Please wait while we load your page...
 

Announcements

PHP Manual :: Examples



Predefined Constants || PCRE Patterns || PCRE || PHP Manual

Example #1 Examples of valid patterns

  • /<\/\w+>/
  • |(\d{3})-\d+|Sm
  • /^(?i)php[34]/
  • {^\s+(\s+)?$}

Example #2 Examples of invalid patterns

  • /href='(.*)' - missing ending delimiter
  • /\w+\s*\w+/J - unknown modifier 'J'
  • 1-\d3-\d3-\d4| - missing starting delimiter



Predefined Constants || PCRE Patterns || PCRE || PHP Manual
Live Chat Not Available