<?php$string = "example.com/TARGET/noneed/noneed/noooo";preg_match("#/(.*?)/#", $string, $match);echo $match[1]; ?>
Standard input is empty
TARGET
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!