Crystina
init
0a97af6
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Data File Test</title>
</head>
<body>
<h1>Data File Test</h1>
<div id="results"></div>
<script>
async function testFileLoading() {
const results = document.getElementById('results');
// Test conferences file
try {
console.log('Testing conferences file...');
const confResponse = await fetch('data/unique_conferences.json');
console.log('Conferences status:', confResponse.status);
if (confResponse.ok) {
const confData = await confResponse.json();
results.innerHTML += `<p>βœ… Conferences file loaded successfully. Found ${Object.keys(confData).length} conferences.</p>`;
} else {
results.innerHTML += `<p>❌ Conferences file failed to load. Status: ${confResponse.status}</p>`;
}
} catch (error) {
results.innerHTML += `<p>❌ Conferences file error: ${error.message}</p>`;
}
// Test BibTeX file
try {
console.log('Testing BibTeX file...');
const bibResponse = await fetch('data/multilingual_papers.bib');
console.log('BibTeX status:', bibResponse.status);
if (bibResponse.ok) {
const bibText = await bibResponse.text();
results.innerHTML += `<p>βœ… BibTeX file loaded successfully. Size: ${(bibText.length / 1024 / 1024).toFixed(2)} MB</p>`;
// Count entries
const entries = bibText.split(/(?=@)/);
results.innerHTML += `<p>πŸ“Š Found ${entries.length} potential BibTeX entries</p>`;
} else {
results.innerHTML += `<p>❌ BibTeX file failed to load. Status: ${bibResponse.status}</p>`;
}
} catch (error) {
results.innerHTML += `<p>❌ BibTeX file error: ${error.message}</p>`;
}
}
// Run test when page loads
window.addEventListener('load', testFileLoading);
</script>
</body>
</html>