src/RpkUtils/Sysinfo/Server.php
public static function docroot()
    {
        if(!empty($_SERVER['DOCUMENT_ROOT'])){
            $docroot = str_replace('\\','/',$_SERVER['DOCUMENT_ROOT']);
        }else{
            $docroot = str_replace('\\','/',dirname(__FILE__));
        }
        
        return $docroot;
    }
public static function docroot()
    {
        if(!empty($_SERVER['DOCUMENT_ROOT'])){
            $docroot = str_replace('\\','/',$_SERVER['DOCUMENT_ROOT']);
        }else{
            $docroot = str_replace('\\','/',dirname(__FILE__));
        }
        
        return $docroot;
    }
public static function docroot ( ) { if ( ! empty ( $ _SERVER [ 'DOCUMENT_ROOT' ] ) ) { $ docroot = str_replace ( '\\' , '/' , $ _SERVER [ 'DOCUMENT_ROOT' ] ) ; } else { $ docroot = str_replace ( '\\' , '/' , dirname ( __FILE__ ) ) ; } return $ docroot ; }
Server document root
@return string
Server document root