The realpath() function returns the absolute path.
This function removes all symbolic links (such as '/./', '/../' and redundant '/') and returns the absolute pathname.
On failure, the function returns FALSE.
realpath(path)
parameter | describe |
---|---|
path | Required. Specifies the path to be checked. |
<?phpecho realpath("test.txt");?>
The above code will output:
C:Inetpubtestwebtest.txt