<?php $str = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/60.0.3112.90 Safari/537.36"; $search = "Chr"; Preg_match("/". $search . ".*?\/\d+\.\d+\.\d+\.\d+/", $str, $match); Var_dump($match);
You have javascript disabled. You will not be able to edit any code.