fork(2) download
  1. <?php
  2.  
  3. $str = 'VN7-572G-75AJ(NX.G6GSA.001)';
  4. preg_match('#^([^(]*)\(([^()]*)\)$#', $str, $matches);
  5. echo $matches[1] . "\n" . $matches[2];
Success #stdin #stdout 0.01s 52488KB
stdin
Standard input is empty
stdout
VN7-572G-75AJ
NX.G6GSA.001