PHP ServerPath
<?php
echo $_SERVER['DOCUMENT_ROOT'];
?>
Worrisome Worm
<?php
echo $_SERVER['DOCUMENT_ROOT'];
?>
<?php
$realpath = realpath();
echo("This program is running in $realpath directory");
?>