getCanonicalPath

Returns the canonical path of the input path. If a directory a trailing slash is used on lucee, but not on ACF.

getCanonicalPath(path) → returns string

getCanonicalPath Argument Reference

path string
Required

Compatibility

ColdFusion:

Version 2016.0.7+ Added to ColdFusion 2018 update 1.

Examples
Sample code invoking the getCanonicalPath function

Returns the canonical path of the input path.

writeOutput( getCanonicalPath(getBaseTemplatePath()) );

Fork me on GitHub