Advertisement
Guest User

Untitled

a guest
May 31st, 2019
145
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.25 KB | None
  1. // Can anyone tell me why this regular expression does not match? It matches fine in an online tester.
  2.  
  3. var_dump([$this->$attribute, preg_match('/^\d{1,5}$/g', $this->$attribute)]); exit;
  4.  
  5. array(2) {
  6. [0]=>
  7. string(5) "10123"
  8. [1]=>
  9. bool(false)
  10. }
Advertisement
RAW Paste Data Copied
Advertisement