; patch path-thru so it can return a directory
path-thru: func [url /local purl][
if file? url [return url]
if not all [purl: decode-url url purl/host] [return none]
rejoin [view-root/public slash purl/host slash any [purl/path ""] any
[purl/target ""]]
]
Here's the original source for comparison:
path-thru: func [url /local purl][
if file? url [return url]
if not all [purl: decode-url url purl/target purl/host] [return none]
rejoin [view-root/public slash purl/host slash any [purl/path ""]
purl/target]
]
In the following examples, the original path-thru returns none.
Kind of irritating. The patched version returns what I would
expect.
path-thru http://somewhere.com ; no path and no target
path-thru http://somewhere.com/adir/ ; no target
Anton.
--
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the
subject, without the quotes.