Regular Expression to parse a string from end until a delimiter is reached(Perl)

Posted by Zerobu on Stack Overflow See other posts from Stack Overflow or by Zerobu
Published on 2010-03-20T22:04:12Z Indexed on 2010/03/20 22:11 UTC
Read the original article Hit count: 310

Filed under:
|
|

Hello, I need a regular expression to parse a text, the text is a URL. The URL is http://www.foo.com/bar/hello.txt. I want to get rid of the hello.txt, the delimiter is the slash. I would like to get http://www.foo.com/bar/

© Stack Overflow or respective owner

Related posts about perl

Related posts about parsing