Skip to content

Instantly share code, notes, and snippets.

@userlond
userlond / find_relative_path.func.php
Last active February 3, 2016 11:51 — forked from ohaal/find_relative_path.func.php
Find the relative path between two paths
<?php
/**
*
* Find the relative file system path between two file system paths
*
* @param string $frompath Path to start from
* @param string $topath Path we want to end up in
*
* @return string Path leading from $frompath to $topath
*/