diff --git a/.gitignore b/.gitignore index b909271..0f4f902 100644 --- a/.gitignore +++ b/.gitignore @@ -2,4 +2,5 @@ project.json *.db .idea/ *.sql -vendor/ \ No newline at end of file +vendor/ +.vs diff --git a/.vs/slnx.sqlite b/.vs/slnx.sqlite deleted file mode 100644 index f70484f..0000000 Binary files a/.vs/slnx.sqlite and /dev/null differ diff --git a/.vs/slnx.sqlite-journal b/.vs/slnx.sqlite-journal deleted file mode 100644 index 1e46394..0000000 Binary files a/.vs/slnx.sqlite-journal and /dev/null differ diff --git a/Source/assets/html/TOS.twig b/Source/assets/html/TOS.twig index bc2dfb7..18a7bd3 100644 --- a/Source/assets/html/TOS.twig +++ b/Source/assets/html/TOS.twig @@ -102,6 +102,10 @@ cookieconsent_status Cookie alert visibility + + Google Analytics Cookies + Track your navigation on CodeShare +

Disclosure Of Data

diff --git a/Source/assets/html/about.twig b/Source/assets/html/about.twig index 0123e91..9d7d7ad 100644 --- a/Source/assets/html/about.twig +++ b/Source/assets/html/about.twig @@ -12,7 +12,7 @@
Open source licenses

Bootstrap 3 by Twitter - Licensed under MIT

Paper theme to Boostrap 3 by Bootswatch - Licensed under MIT

-

jQuery 3.2.1 by jQuery - Licensed under MIT

+

jQuery by jQuery - Licensed under MIT

Highlight.js by Ivan Sagalev - Licensed under BSD

Cookie Consent by Insites - Licensed under MIT

diff --git a/Source/assets/html/add.twig b/Source/assets/html/add.twig index 950dd6b..a7769d5 100644 --- a/Source/assets/html/add.twig +++ b/Source/assets/html/add.twig @@ -28,10 +28,10 @@
- +
- +
@@ -73,4 +73,25 @@ width: 100%; } +{% endblock %} + +{% block js %} + {% endblock %} \ No newline at end of file diff --git a/Source/assets/html/base.twig b/Source/assets/html/base.twig index 66041ad..343cfbc 100644 --- a/Source/assets/html/base.twig +++ b/Source/assets/html/base.twig @@ -7,7 +7,7 @@ - + {##} {% block css %}{% endblock %} @@ -49,10 +49,41 @@ {% endblock %} - + + diff --git a/Source/assets/js/functions.js b/Source/assets/js/functions.js index 8d80aeb..6090706 100644 --- a/Source/assets/js/functions.js +++ b/Source/assets/js/functions.js @@ -154,6 +154,10 @@ function onScroll() { //From https://stackoverflow.com/questions/35297919/javascript-select-all-text-inside-a-pre-code-block-on-double-click window.onload = function(){ + if(!comprobarCookie('cookieconsent_status') || obtenerCookie('cookieconsent_status')=='deny'){ + deleteCookies(); + } + document.body.addEventListener('dblclick', function(e){ var target = e.target || e.srcElement; if (target.className.indexOf("highlight") !== -1 || target.parentNode.className.indexOf("highlight") !== -1){ @@ -174,4 +178,11 @@ window.onload = function(){ } }); -}; \ No newline at end of file +}; + +function deleteCookies() { + var theCookies = document.cookie.split(';'); + for (var i = 0 ; i < theCookies.length; i++) { + document.cookie = theCookies[i].split('=')[0] + '=; path=/; expires=Thu, 01 Jan 1970 00:00:01 GMT;'; + } +} \ No newline at end of file diff --git a/Source/doc/ROLES b/Source/doc/ROLES deleted file mode 100644 index 6175c6d..0000000 --- a/Source/doc/ROLES +++ /dev/null @@ -1,5 +0,0 @@ -User's roles -0: Normal user -1: Normal user with ban -2: Moderator -3: Administrator \ No newline at end of file diff --git a/Source/src/app.php b/Source/src/app.php index 3038f81..8e09744 100644 --- a/Source/src/app.php +++ b/Source/src/app.php @@ -1,5 +1,5 @@