Can someone show me a regex that will remove the page part from a string.
My strings are either
/section/
/section/page.html
/section/subsection/page.html
I need a regexp that would return
/section/
/section/
/section/subsection/
You can assume the file ext is always .html and the strings are relative (no http://host:port)
Thanks!
I think you’re looking for: