Skip to content

Instantly share code, notes, and snippets.

View allanchangcl's full-sized avatar
🏠
Working from home

Allan Chang allanchangcl

🏠
Working from home
View GitHub Profile
@ohaal
ohaal / find_relative_path.func.php
Created June 15, 2012 11:47
Find the relative path between two paths
/**
*
* 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
*/
function find_relative_path ( $frompath, $topath ) {