competitions/templates/index.html [64:81]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
.then(response => {
if (!response.ok) {
throw new Error('Network response was not ok');
}
return response.json(); // Parse the JSON response
})
.then(data => {
// Populate the 'content' div with the HTML from the response
const contentDiv = document.getElementById('content');
contentDiv.innerHTML = marked.parse(data.response);
addTargetBlankToLinks();
articleLoadingSpinner.classList.add('hidden');
})
.catch(error => {
console.error('There has been a problem with your fetch operation:', error);
articleLoadingSpinner.classList.add('hidden');
});
}
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
competitions/templates/index.html [253:270]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
.then(response => {
if (!response.ok) {
throw new Error('Network response was not ok');
}
return response.json(); // Parse the JSON response
})
.then(data => {
// Populate the 'content' div with the HTML from the response
const contentDiv = document.getElementById('content');
contentDiv.innerHTML = marked.parse(data.response);
addTargetBlankToLinks();
articleLoadingSpinner.classList.add('hidden');
})
.catch(error => {
console.error('There has been a problem with your fetch operation:', error);
articleLoadingSpinner.classList.add('hidden');
});
}
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -