Skip to content

Instantly share code, notes, and snippets.

@Itachi261092
Created October 12, 2015 13:00
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Itachi261092/968d644d423548c79a37 to your computer and use it in GitHub Desktop.
Save Itachi261092/968d644d423548c79a37 to your computer and use it in GitHub Desktop.
[PHP] Get absolute web-server path / Получаем абсолютный путь к веб-серверу
<?php
echo 'Document root: '.$_SERVER['DOCUMENT_ROOT'].'<br>';
echo 'Полный путь к скрипту и его имя: '.$_SERVER['SCRIPT_FILENAME'].'<br>';
echo 'Имя скрипта: '.$_SERVER['SCRIPT_NAME'];
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment