Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
"jbroadway/urlify": "^1.0",
"pragmarx/google2fa": "^8.0",
"bacon/bacon-qr-code": "^3.0",
"phpmailer/phpmailer": "^6.5"
"phpmailer/phpmailer": "^6.5",
"matomo/matomo-php-tracker": "^3.4"
},
"autoload": {
"files": [
Expand Down
58 changes: 57 additions & 1 deletion composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

40 changes: 40 additions & 0 deletions lang/en_US.ini
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,16 @@ github_pre_release = "Github pre-release"
google_analytics = "Google Analytics"
google_analytics_legacy = "Google Analytics (legacy)"
google_search_console = "Google Search Console"
matomo_analytics = "Matomo Analytics"
matomo_url = "Matomo URL"
matomo_site_id = "Matomo Site ID"
matomo_authtoken = "Matomo Auth. Token"
matomo_track_type = "Matomo Tracking Type"
matomo_track_type_js = "Javascript - Client side (can be ditched by browser extensions)"
matomo_track_type_php = "PHP Backend - Server side"
matomo_use_cookies = "Matomo cookies"
matomo_use_cookies_yes = "Use cookies (better analytics)"
matomo_use_cookies_no = "Do NOT use cookies (easier European GDPR compliance)"
home = "Home"
if_left_empty_we_will_excerpt_it_from_the_content_below = "If leave empty we will excerpt it from the content below"
if_the_url_is_left_empty_we_will_use_the_page_title = "If the url leave empty we will use the page title"
Expand Down Expand Up @@ -407,3 +417,33 @@ backtotop = "Back to top"
subpages = "Sub pages"
getstarted = "Get started"
onthispage = "On this page"
enable_jstime="Enable Javascript and timestamp anti-spam protection"
jstime_desc="Usually bots dont't use Javascript. Form also checks if submitted between 3 and 600 seconds (preventing bots fast submission)"
comment_email_admin_awaiting="New comment awaiting moderation"
comment_email_admin_new="New comment"
comment_email_subscription_subject = "Subscription confirmation to"
comment_email_new = "New comment on"
comment_email_from = "From"
comment_email_moderate = "Moderate comments"
comment_email_new_subscribed = "New reply on a subscribed thread"
comment_email_new_replied = "Someone replied to your comment on"
comment_email_view_comment = "View comment"
comment_subscribe_confirmation = "Subscription confirmation to"
comment_subscribe_thread = "Thread subscription at"
comment_subscribe_request = "We received a subscription request to a thread at"
comment_subscribe_never_requested = "If you never visited the site or requested to be notified on thread messages, please ignore this email."
comment_subscribe_click = "Click"
comment_subscribe_here = "HERE"
comment_subscribe_confirm_message = "to confirm your subscription and start receiving notification emails on replies on the thread."
comment_subscribe_unsubscribe_message = "You can unsubscribe all notifications from"
comment_subscribe_unsubscribe_anytime = "at any time using this link"
comment_unsubscribe = "unsubscribe"
sysmsg_subscribe_success = "Your will receive now new comment notifications on the subscribed threads."
sysmsg_subscribe_fail = "Something went wrong during subscription verification process."
sysmsg_unsubscribe_success = "You have successfully unsubscribed from notification emails."
sysmsg_unsubscribe_fail = "Something wrong during unsubscription process"


posts_not_found = "Posts not found!"
page_not_found = "Page not found!"

8 changes: 4 additions & 4 deletions lang/it_IT.ini
Original file line number Diff line number Diff line change
Expand Up @@ -403,7 +403,7 @@ comment_submission_error_short = "Il commento è richiesto e deve essere almeno
comment_submission_error_spam = "SPAM rilevato!"
pending_comments = "Commenti in attesa"
level = "Livello"
backtotop = "Back to top"
subpages = "Sub pages"
getstarted = "Get started"
onthispage = "On this page"
backtotop = "Torna in cima"
subpages = "Sottopagine"
getstarted = "Per cominciare"
onthispage = "Su questa pagina"
64 changes: 64 additions & 0 deletions system/admin/admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -1728,82 +1728,133 @@ function clear_post_cache($post_date, $post_tag, $post_url, $filename, $category
if (file_exists($p)) {
unlink($p);
}
if (file_exists($p . '.meta.json')) {
unlink($p . '.meta.json');
}

// Delete post permalink
$pp = 'cache/page/' . $b . 'post#' . $post_url . '.cache';
if (file_exists($pp)) {
unlink($pp);
}
if (file_exists($pp . '.meta.json')) {
unlink($pp . '.meta.json');
}

// Delete homepage
$yd = 'cache/page/' . $b . '.cache';
if (file_exists($yd)) {
unlink($yd);
}
if (file_exists($yd . '.meta.json')) {
unlink($yd . '.meta.json');
}
foreach (glob('cache/page/' . $b . '~*.cache', GLOB_NOSORT) as $file) {
unlink($file);
}
foreach (glob('cache/page/' . $b . '~*.cache.meta.json', GLOB_NOSORT) as $filemeta) {
unlink($filemeta);
}

// Delete year
$yd = 'cache/page/' . $b . 'archive#' . $t[0] . '.cache';
if (file_exists($yd)) {
unlink($yd);
}
if (file_exists($yd . '.meta.json')) {
unlink($yd . '.meta.json');
}
foreach (glob('cache/page/' . $b . 'archive#' . $t[0] . '~*.cache', GLOB_NOSORT) as $file) {
unlink($file);
}
foreach (glob('cache/page/' . $b . 'archive#' . $t[0] . '~*.cache.meta.json', GLOB_NOSORT) as $filemeta) {
unlink($filemeta);
}

// Delete year-month
$yd = 'cache/page/' . $b . 'archive#' . $t[0] . '-' . $t[1] . '.cache';
if (file_exists($yd)) {
unlink($yd);
}
if (file_exists($yd . '.meta.json')) {
unlink($yd . '.meta.json');
}
foreach (glob('cache/page/' . $b . 'archive#' . $t[0] . '-' . $t[1] . '~*.cache', GLOB_NOSORT) as $file) {
unlink($file);
}
foreach (glob('cache/page/' . $b . 'archive#' . $t[0] . '-' . $t[1] . '~*.cache.meta.json', GLOB_NOSORT) as $filemeta) {
unlink($filemeta);
}

// Delete year-month-day
$yd = 'cache/page/' . $b . 'archive#' . $t[0] . '-' . $t[1] . '-' . $t[2] . '.cache';
if (file_exists($yd)) {
unlink($yd);
}
if (file_exists($yd . '.meta.json')) {
unlink($yd . '.meta.json');
}
foreach (glob('cache/page/' . $b . 'archive#' . $t[0] . '-' . $t[1] . '-' . $t[2] . '~*.cache', GLOB_NOSORT) as $file) {
unlink($file);
}
foreach (glob('cache/page/' . $b . 'archive#' . $t[0] . '-' . $t[1] . '-' . $t[2] . '~*.cache.meta.json', GLOB_NOSORT) as $filemeta) {
unlink($filemeta);
}

// Delete tag
foreach ($c as $tag) {
$yd = 'cache/page/' . $b . 'tag#' . $tag . '.cache';
if (file_exists($yd)) {
unlink($yd);
}
if (file_exists($yd . '.meta.json')) {
unlink($yd . '.meta.json');
}
foreach (glob('cache/page/' . $b . 'tag#' . $tag . '~*.cache', GLOB_NOSORT) as $file) {
unlink($file);
}
foreach (glob('cache/page/' . $b . 'tag#' . $tag . '~*.cache.meta.json', GLOB_NOSORT) as $filemeta) {
unlink($filemeta);
}
}

// Delete search
foreach (glob('cache/page/' . $b . 'search#*.cache', GLOB_NOSORT) as $file) {
unlink($file);
}
foreach (glob('cache/page/' . $b . 'search#*.cache.meta.json', GLOB_NOSORT) as $filemeta) {
unlink($filemeta);
}

// Delete category
$cc = 'cache/page/' . $b . 'category#' . $category . '.cache';
if (file_exists($cc)) {
unlink($cc);
}
if (file_exists($cc . '.meta.json')) {
unlink($cc . '.meta.json');
}
foreach (glob('cache/page/' . $b . 'category#' . $category . '~*.cache', GLOB_NOSORT) as $file) {
unlink($file);
}
foreach (glob('cache/page/' . $b . 'category#' . $category . '~*.cache.meta.json', GLOB_NOSORT) as $filemeta) {
unlink($filemeta);
}

// Delete type
$tp = 'cache/page/' . $b . 'type#' . $type . '.cache';
if (file_exists($tp)) {
unlink($tp);
}
if (file_exists($tp . '.meta.json')) {
unlink($tp . '.meta.json');
}
foreach (glob('cache/page/' . $b . 'type#' . $type . '~*.cache', GLOB_NOSORT) as $file) {
unlink($file);
}
foreach (glob('cache/page/' . $b . 'type#' . $type . '~*.cache.meta.json', GLOB_NOSORT) as $filemeta) {
unlink($filemeta);
}

// Get cache post author
$arr = pathinfo($filename, PATHINFO_DIRNAME);
Expand All @@ -1813,9 +1864,16 @@ function clear_post_cache($post_date, $post_tag, $post_url, $filename, $category
if (file_exists($a)) {
unlink($a);
}
if (file_exists($a . '.meta.json')) {
unlink($a . '.meta.json');
}

foreach (glob('cache/page/' . $b . 'author#' . $x[1] . '~*.cache', GLOB_NOSORT) as $file) {
unlink($file);
}
foreach (glob('cache/page/' . $b . 'author#' . $x[1] . '~*.cache.meta.json', GLOB_NOSORT) as $filemeta) {
unlink($filemeta);
}
}

function clear_page_cache($url)
Expand All @@ -1825,13 +1883,19 @@ function clear_page_cache($url)
if (file_exists($p)) {
unlink($p);
}
if (file_exists($p . '.meta.json')) {
unlink($p . '.meta.json');
}
}

function clear_cache()
{
foreach (glob('cache/page/*.cache', GLOB_NOSORT) as $file) {
unlink($file);
}
foreach (glob('cache/page/*.cache.meta.json', GLOB_NOSORT) as $file) {
unlink($file);
}
}

function valueMaker($value)
Expand Down
3 changes: 3 additions & 0 deletions system/admin/views/clear-cache.html.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@
foreach (glob('cache/page/*.cache', GLOB_NOSORT) as $file) {
unlink($file);
}
foreach (glob('cache/page/*.cache.meta.json', GLOB_NOSORT) as $filemeta) {
unlink($filemeta);
}

echo i18n('All_cache_has_been_deleted');

Expand Down
Loading