There is a string, there are many substrings of the type /dream/aim/ . How to pull aim and further everything that is enclosed in slashes after a dream ? Something tried to navayat, not furychit:
preg_match_all("/\/dream\/(*\w)\//", $string, $matches);
preg_match_all("~/dream/([^/]+)~", $string, $matches); print_r($matches[1]);- Wiktor Stribiżew