site/docs/overrides/main.html
2025-11-19 15:06:16 +01:00

49 lines
1.5 KiB
HTML

{% extends "base.html" %}
{% block extrahead %}
<meta name="robots"
content="nocache, noindex, noimageindex, nofollow, noarchive, nosnippet, nositelinkssearchbox, noai, noimageai">
{% endblock %}
{% block scripts %}
{{ super() }}
<!-- Script to protect content on the website -->
<script>
// Prevent right-click context menu
document.addEventListener('contextmenu', function (e) {
e.preventDefault();
});
// Prevent text selection
document.addEventListener('selectstart', function (e) {
e.preventDefault();
});
// Block Ctrl+C and other keyboard shortcuts for copying
document.addEventListener('keydown', function (e) {
if (e.ctrlKey && e.key === 'c') { // Blocks Ctrl+C
e.preventDefault();
}
if (e.ctrlKey && e.shiftKey && e.key === 'v') { // Blocks Ctrl+Shift+V
e.preventDefault();
}
});
// Additional measures for image protection
document.addEventListener('contextmenu', function (e) {
if (e.target.tagName.toLowerCase() === 'img') {
e.preventDefault();
}
});
</script>
<!-- Analytics script to measure the performance of the website -->
<script
src="https://analytics.gugulet.hu/api/script.js"
data-site-id="1"
defer
></script>
{% endblock %}