title: Portable paths and PHP CLI
body: <p>So I got burned again by forgetting that the CLI does not have $_SERVER['DOCUMENT_ROOT'] defined.</p>
  
  <p>What is the best way to get a portable/relative path in a PHP script that will be run by cron?</p>