Get absolute path on webspace
Tip by Computer Expert | Last update on 2020-02-04 | Created on 2012-03-10
Sometimes, you need the absolute path of your web space, for example, to save or open files. Unfortunately, the path is usually more than unknown, especially for users of shared hosting providers.
This shall bring light into the darkness:
echo getcwd();
With the simple function getcwd() using PHP, you can easily and quickly get the absolute path of where the file containing the script is located.
About the Author
The author has not added a profile short description yet.
Show Profile
Related Topics
Convert many CSV Files to XLSX or ODS Spreadsheets
Tutorial | 0 Comments
VirtualBox: Change Date and Time
Tutorial | 10 Comments
Program in ZIP-Folder
Info | 0 Comments
What is a non breaking space?
Info | 0 Comments
Rewrite Text Files with a fixed Line Length
Tutorial | 0 Comments
HTML: No line break between particular words
Tip | 0 Comments
Repair Text Files with mixed Line Breaks
Tutorial | 0 Comments
Important Note
Please note: The contributions published on askingbox.com are contributions of users and should not substitute professional advice. They are not verified by independents and do not necessarily reflect the opinion of askingbox.com. Learn more.
Participate
Ask your own question or write your own article on askingbox.com. That’s how it’s done.