Forum
How to get the URL to a page w/o the page itself
I would like to know the path to a page without the page itself. So for
`/the-boat/history.php'
I would like
`/the-boat/'
returned
the same returned for
`/the-boat/index.php'
and for
`/the-boat/leaking.php'
but for
`/the-docks/history.php'
I would get
`/the-docks/'
Sorry that's a longwinded explanation. I've looked at https://docs.grabaperch.com/docs/navigation/perch-page-url but it doesn't quite give me what I want. Is there some other Perch construct I can use to return this (there does not seem to be consensus on a reliable way to do it in raw PHP)?
Thanks in advance for any pointers ^_^
Hi Alan,
I think you should be able to do it with this:
Thanks Simon, works a treat! Most grateful ^_^
Worked for me also, thanks Simon.
Great! :)