add function to retrieve document path