Relative URI Functions


Introduction

These functions manipulate relative URI references.

The following assumptions must hold true:

  1. All URIs are relative.

  2. No URI contains the ../ sequence which would effectively move up the hierarchy.

If these assumptions do not hold, the results are unpredictable.

Table of Contents

count.uri.path.depth — Count the number of path components in a relative URI
trim.common.uri.paths — Trim common leading path components from a relative URI
resolve.path — Resolve any ../ in path, except leading ../
dirname — Return directory part of a path