<commit_before><!doctype html>
<html>
<head>
<meta charset="UTF-8">
<title>Client Tests</title>
<script type="text/javascript" src="../HTTPRequest.js"></script>
<script type="text/javascript">

function newRequestID(tag, id)
{
	console.log('new id: ' + tag + ' , ' + id);
}

HTTPRequest.setnewRequestCallback(newRequestID);

function processedID(tag, id)
{
	console.log('processed: ' + tag + ' , ' + id);
}

HTTPRequest.setProcessedCallback(processedID);

function ajaxLoaderStart()
{
	console.log('Started');
}

HTTPRequest.setAjaxStart(ajaxLoaderStart);

function ajaxLoaderStop()
{
	console.log('Stopped');
}

HTTPRequest.setAjaxStop(ajaxLoaderStop);

function test_Get()
{
	var reqID = HTTPRequest.get('http://ajaxtests/get_test.php', function(status, headers, content)
	{
		console.log(status, headers, content);
	}, {TAG: 'test'});
	
	console.log(reqID);
	
	return false;
}

function test_LongGet()
{
	var reqID = HTTPRequest.get('http://ajaxtests/long_request.php', function(status, headers, content)
	{
		console.log(status, headers, content);
	});
	
	console.log(reqID);
	
	//HTTPRequest.stopID(1);
	//HTTPRequest.stopAll();
	
	//HTTPRequest.stopTag('untagged');
	
	return false;
}

function test_Post()
{
	HTTPRequest.post('http://ajaxtests/post_test.php', {hello: 'world'} ,function(status, headers, content)
	{
		console.log(status, headers, content);
	});
	return false;
}

function test_JSON()
{
	HTTPRequest.get('http://ajaxtests/json.php', function(status, headers, content)
	{
		console.log(status, headers, content);<commit_msg>cleaned up some comments<commit_after><!doctype html>
<html>
<head>
<meta charset="UTF-8">
<title>Client Tests</title>
<script type="text/javascript" src="../HTTPRequest.js"></script>
<script type="text/javascript">

//stop functions
	//HTTPRequest.stopID(1);
	//HTTPRequest.stopAll();
	//HTTPRequest.stopTag('untagged');
	
//callbacks

function newRequestID(tag, id)
{
	console.log('new id: ' + tag + ' , ' + id);
}

HTTPRequest.setnewRequestCallback(newRequestID);

function processedID(tag, id)
{
	console.log('processed: ' + tag + ' , ' + id);
}

HTTPRequest.setProcessedCallback(processedID);

function ajaxLoaderStart()
{
	console.log('Started');
}

HTTPRequest.setAjaxStart(ajaxLoaderStart);

function ajaxLoaderStop()
{
	console.log('Stopped');
}

HTTPRequest.setAjaxStop(ajaxLoaderStop);

function test_Get()
{
	var reqID = HTTPRequest.get('http://ajaxtests/get_test.php', function(status, headers, content)
	{
		console.log(status, headers, content);
	}, {TAG: 'test'});
	
	console.log(reqID);
	
	return false;
}

function test_LongGet()
{
	var reqID = HTTPRequest.get('http://ajaxtests/long_request.php', function(status, headers, content)
	{
		console.log(status, headers, content);
	});
	
	console.log(reqID);
	
	return false;
}

function test_Post()
{
	HTTPRequest.post('http://ajaxtests/post_test.php', {hello: 'world'} ,function(status, headers, content)
	{
		console.log(status, headers, content);
	});
	return false;
}

function test_JSON()
{
	HTTPRequest.get('http://ajaxtests/json.php', function(status, headers, content)
	{
		console.log(status, headers, content);
{'fraction_non_alphanumeric': 0.17246885978920473, 'fraction_numerical': 0.0012775471095496647, 'mean_word_length': 5.525, 'pattern_counts': {'":': 0, '<': 21, '<?xml version=': 0, '>': 21, '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': '4190965', 'n_tokens_mistral': 1122, 'n_tokens_neox': 1078, 'n_words': 187}