Tag Archive | "uri"

PHP : Strip filename from a URL

Saturday, April 26, 2008

0 Comments

Using PHP, you might need to strip the path from a URL, leaving behind just the filename at the end of the URL. You can achieve this with a regular expression pattern of course, but I have a much simpler solution. See the example code below.

Continue reading...