You appear to be a bot. Output may be restricted
Description
Get the document root suffix
This routine finds the subdirectory under which this local version of the website is installed. Sometimes we need to remove this from index lookups but add it to links!
Usage
bw_get_docroot_suffix();
Parameters
Returns
void
TO DO
Shouldn't this function be deprecated?
Source
File name: oik-bwtrace/libs/bobbfunc.php
Lines:
1 to 17 of 17
function bw_get_docroot_suffix() { bw_backtrace( BW_TRACE_DEBUG ); $docroot_suffix = "/"; if ( $_SERVER['SERVER_NAME'] == bw_get_option( "betterbyfar") ) { $exdr = explode( '/', $_SERVER["DOCUMENT_ROOT"] ); $exsf = explode( '/', $_SERVER['SCRIPT_FILENAME'] ); $docroot_suffix = '/' . $exsf[ count( $exdr) ] . '/'; // bw_debug( "_SERVER[DOCUMENT_ROOT]: " . $_SERVER["DOCUMENT_ROOT"] ); // bw_debug( "_SERVER[REQUEST_URI]: " . $_SERVER['REQUEST_URI'] ); // bw_debug( "_SERVER[SCRIPT_FILENAME]: " . $_SERVER['SCRIPT_FILENAME'] ); // bw_debug( "docroot_suffix: " . $docroot_suffix ); } return( $docroot_suffix ); }