<commit_before><?php if ( ! defined('ABSPATH')) exit('No direct script access allowed');
/**
 * This file includes common functions and variables and loads EDMS class files.
 */

function get_name() {
	echo "Elite Dealer Management System";
}

function get_shortname() {
	echo "EDMS";
}

/**
 *	Create a page id using the loaded file's name
 *
 *	Example: index.php creates id of index
 *
 *	@return id name
 */
function page_id() {
	return basename($_SERVER['PHP_SELF'], ".php");
}

/**
 *	Is current loaded page the specified page?
 *
 *	@param string $page 
 *	@return boolean
 */
function is_page( $page = '' ) {
	if ( page_id() === (string) $page )
		return true;

	return false;
}

function get_template_part( $path = null, $name = '', $ext = ".php" ) {
	$name = (string) $name;

	$file = $path . '/' . $name . $ext;

	if ( file_exists( $file ) )
		require $file;
	else
		echo "Included file: '" . $file . "'' does not exist";
}

function get_navbar() {
	get_template_part( "../functions" , "navbar" );
}

/* Don't load file if global database variable is already set */
if ( ! isset( $edmsdb ) )
	/* Includes database class and sets $edmsdb global */
	include 'database.php';

?><commit_msg>Fix get_template_part() bug<commit_after><?php if ( ! defined('ABSPATH')) exit('No direct script access allowed');
/**
 * This file includes common functions and variables and loads EDMS class files.
 */

function get_name() {
	echo "Elite Dealer Management System";
}

function get_shortname() {
	echo "EDMS";
}

/**
 *	Create a page id using the loaded file's name
 *
 *	Example: index.php creates id of index
 *
 *	@return id name
 */
function page_id() {
	return basename($_SERVER['PHP_SELF'], ".php");
}

/**
 *	Is current loaded page the specified page?
 *
 *	@param string $page 
 *	@return boolean
 */
function is_page( $page = '' ) {
	if ( page_id() === (string) $page )
		return true;

	return false;
}

function get_template_part( $name = '', $path = null,  $ext = ".php" ) {
	$name = (string) $name;

	$file = $path . '/' . $name . $ext;

	if ( file_exists( $file ) )
		require $file;
	else
		echo "Included file: '" . $file . "'' does not exist";
}

function get_navbar() {
	get_template_part( "navbar" , "../functions" );
}

/* Don't load file if global database variable is already set */
if ( ! isset( $edmsdb ) )
	/* Includes database class and sets $edmsdb global */
	include 'database.php';

?>
{'fraction_non_alphanumeric': 0.16009954375777685, 'fraction_numerical': 0.0, 'mean_word_length': 3.5681818181818183, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5864954', 'n_tokens_mistral': 825, 'n_tokens_neox': 806, 'n_words': 264}