0){ $L1 = 'true'; } $dirLevel = strstr($url, '/mtn/'); if (strlen($dirLevel) > 0){ $L1 = 'true'; } $dirLevel = strstr($url, '/theaterHistory/'); if (strlen($dirLevel) > 0){ $L1 = 'true'; } if ($L1 == 'true'){ include_once( '../includes/php_vars.inc'); }else{ include_once( 'includes/php_vars.inc'); } $pagename = "The Center for Arts in Natick"; $url = $_SERVER['PHP_SELF']; $url = strrchr($url, '/'); $url = substr($url, 1); $db_return = @mysql_connect($host, $user, $password); if ($db_return) { mysql_select_db($database); $query = "SELECT title FROM pagecat WHERE page = '$url'"; $result = mysql_query($query); //$pagename = mysql_error(); $row = mysql_fetch_assoc($result); if (strlen($row) > 0){ $pagename = $pagename . " => " . $row["title"]; } } Print "