фиксы
This commit is contained in:
5
style.c
5
style.c
@@ -1,10 +1,10 @@
|
||||
// Подгрузка CSS
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
int main() {
|
||||
// Проверяем, существует ли файл стилей
|
||||
char css_path[1024] = "/home/romkazvo/www/cgi-bin/style.css";
|
||||
struct stat st;
|
||||
|
||||
@@ -15,8 +15,9 @@ int main() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
// Отдаем CSS с правильными заголовками
|
||||
printf("Content-type: text/css\n");
|
||||
printf("Cache-Control: public, max-age=3600\n\n");
|
||||
printf("Cache-Control: public, max-age=3600\n\n"); // Кэшируем на 1 час
|
||||
|
||||
FILE *css_file = fopen(css_path, "r");
|
||||
if (!css_file) {
|
||||
|
||||
Reference in New Issue
Block a user