----- Original Message ----- From: "lilmouseman" Hi Everyone. First time poster.
My question is about extracting part of a path from the right. e.g. folder/images/testimage.jpg how do I get everything from the right all the way up to the first "/" Thank you in advance. ------------------------------------ Hi Lilmouseman, I see that you were happy with using basename(). >From your question it seems that you are talking about a URL rather than a file path. For file paths, lookup these functions - pathinfo() - http://php.net/manual/en/function.pathinfo.php realpath() - http://php.net/manual/en/function.realpath.php For HTTP paths, lookup these functions - parse_url() - http://php.net/manual/en/function.parse-url.php parse_str() - http://php.net/manual/en/function.parse-str.php For functions that work with URL's or file paths, lookup these functions - dirname() - http://php.net/manual/en/function.dirname.php basename() - http://php.net/manual/en/function.basename.php