Backup database and code changes - 2025-06-09 05:33:32

This commit is contained in:
root
2025-06-09 05:33:32 +00:00
parent 8d431b6cbd
commit c5a09bee5f
29 changed files with 410 additions and 207 deletions

View File

@@ -1,10 +1,7 @@
<?php
// Add inline CSS fix for buttons
$articles_dir = '/var/www/html/blog/articles/';
$files = glob($articles_dir . '*.php');
$inline_css = '
// This file adds inline CSS for button fixes
// It should only output CSS, not modify files
?>
<style>
.btn {
background: #179e83 !important;
@@ -27,23 +24,4 @@ $inline_css = '
background: #11725e !important;
color: white !important;
}
</style>';
foreach ($files as $file) {
$content = file_get_contents($file);
if ($content === false) {
continue;
}
// Add inline CSS right before </head>
if (strpos($content, '</head>') !== false && strpos($content, 'btn-fix-inline') === false) {
$content = str_replace('</head>', $inline_css . "\n<!-- btn-fix-inline -->\n</head>", $content);
file_put_contents($file, $content);
echo "Added inline CSS to: " . basename($file) . "\n";
}
}
// echo "Inline CSS fix complete!\n";
?>
</style>