<?php $item = "component_phase_1"; $match = []; preg_match("/([a-z]+_[a-z]+_*[a-z]+)_?(\d+)?/", $item, $match); var_dump($match);
You have javascript disabled. You will not be able to edit any code.