see answer: PHP Directories - Best Practice
I like to use:
config.php (sits in the root)
define('ROOT_SYS',dirname(__FILE__).'/'); //$_SERVER["DOCUMENT_ROOT"] for root access
this allows me to work on the site locally and on the hosting with no issues. In your case it would look something like:
include(ROOT_SYS . 'classes/browser_detection.php')