Let's say I have a URL: https://somesite.com/0/posts/20/290/755653-Title.html How would I get these variables: /0/, /20/, /290/ ? Note they are variables, they will always be different.
I thought I could get them like so:
$url = '//somesite.com/0/posts/20/290/755653-Title.html';
var_dump(parse_url($url));
but the array doesn't show them as separate variables. Should it be done with a preg_replace instead? I don't think I know how. Thank you for your help.