<?php $str = 'xxABC1xxxABC2xx'; if ( preg_match('/\d[A-Z]+x/', strrev($str), $match) ) echo strrev($match[0]);
You have javascript disabled. You will not be able to edit any code.