function _live_css_document_root in Live CSS 6.2
Same name and namespace in other branches
- 7.2 live_css.module \_live_css_document_root()
Helper function to get the document root for the current Drupal installation. $_SERVER['DOCUMENT_ROOT'] is not reliable across all systems, so we need a way to get the correct value.
1 call to _live_css_document_root()
File
- ./
live_css.module, line 239
Code
function _live_css_document_root() {
$absolute_dir = dirname(__FILE__);
$relative_dir = drupal_get_path('module', 'live_css');
return drupal_substr($absolute_dir, 0, -1 * (1 + drupal_strlen($relative_dir)));
}