How to find the absolute path of your files using php

If like me you were trying to find the absolute path for your files when setting up your zen cart install, I found the following script to be super useful. Can be used anywhere, not just for zen cart!

Just make a blank php file in folder you want to get the path of and paste this:

$path = getcwd();
echo "This is the absolute path: ";
echo $path;

Then just browse to the file and see the path. Quick ‘n easy!

Leave a Reply

Your email address will not be published. Required fields are marked *