Skip to content

Commit 4b83621

Browse files
author
TechStack Global
committed
fix: force CSS cache refresh across all pages with version query string
1 parent 686a3af commit 4b83621

24 files changed

+41
-23
lines changed

about.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap"
2020
rel="stylesheet">
21-
<link rel="stylesheet" href="style.css">
21+
<link rel="stylesheet" href="style.css?v=2">
2222
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
2323
<link rel="icon" type="image/png" sizes="32x32" href="assets/icons/favicon-32.png">
2424
<link rel="icon" type="image/png" sizes="16x16" href="assets/icons/favicon-16.png">

affiliate-disclosure.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<title>Affiliate Disclosure | TechStack Global</title>
88
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap"
99
rel="stylesheet">
10-
<link rel="stylesheet" href="style.css">
10+
<link rel="stylesheet" href="style.css?v=2">
1111
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
1212
<link rel="icon" type="image/png" sizes="32x32" href="assets/icons/favicon-32.png">
1313
<link rel="icon" type="image/png" sizes="16x16" href="assets/icons/favicon-16.png">

amazon-stack.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
content="The definitive guide to Amazon-sourced hardware for students, freelancers, and remote workers. Vetted benchmarks for modern productivity.">
1010
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap"
1111
rel="stylesheet">
12-
<link rel="stylesheet" href="style.css">
12+
<link rel="stylesheet" href="style.css?v=2">
1313
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
1414
<link rel="icon" type="image/png" sizes="32x32" href="assets/icons/favicon-32.png">
1515

blog.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap"
2121
rel="stylesheet">
22-
<link rel="stylesheet" href="style.css">
22+
<link rel="stylesheet" href="style.css?v=2">
2323

2424
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
2525
<link rel="icon" type="image/png" sizes="32x32" href="assets/icons/favicon-32.png">

cache_bust.py

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
import glob
2+
import os
3+
4+
html_files = glob.glob(r'c:\Users\PMLS\Desktop\Youtube Shorts\b2b_blog\**\*.html', recursive=True)
5+
6+
for filepath in html_files:
7+
with open(filepath, 'r', encoding='utf-8') as f:
8+
content = f.read()
9+
10+
# Simple replace
11+
new_content = content.replace('href="style.css"', 'href="style.css?v=2"')
12+
new_content = new_content.replace('href="../style.css"', 'href="../style.css?v=2"')
13+
14+
if new_content != content:
15+
with open(filepath, 'w', encoding='utf-8') as f:
16+
f.write(new_content)
17+
18+
print("Cache busting string added to all HTML files!")

contact.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap"
2121
rel="stylesheet">
22-
<link rel="stylesheet" href="style.css">
22+
<link rel="stylesheet" href="style.css?v=2">
2323
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
2424
<link rel="icon" type="image/png" sizes="32x32" href="assets/icons/favicon-32.png">
2525
<link rel="icon" type="image/png" sizes="16x16" href="assets/icons/favicon-16.png">

index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
<!-- Google Fonts: Inter for that premium tech feel -->
2828
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap"
2929
rel="stylesheet">
30-
<link rel="stylesheet" href="style.css">
30+
<link rel="stylesheet" href="style.css?v=2">
3131

3232
<!-- FontAwesome for Icons -->
3333
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">

posts/apple-macbook-pro-m4-pro-review.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<title>Apple MacBook Pro M4 Pro Review (2026) | TechStack Global</title>
88
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap"
99
rel="stylesheet">
10-
<link rel="stylesheet" href="../style.css">
10+
<link rel="stylesheet" href="../style.css?v=2">
1111

1212
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
1313
<link rel="icon" type="image/png" sizes="32x32" href="../assets/icons/favicon-32.png">

posts/best-headphones-for-classes.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
content="From Sony to Bose, we review the best noise-cancelling headphones for online classes, libraries, and busy homes. Stay focused on your studies in 2026.">
1010
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap"
1111
rel="stylesheet">
12-
<link rel="stylesheet" href="../style.css">
12+
<link rel="stylesheet" href="../style.css?v=2">
1313
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
1414
<link rel="icon" type="image/png" sizes="32x32" href="../assets/icons/favicon-32.png">
1515
</head>

posts/best-laptops-for-students-2026.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
content="The definitive guide to the best laptops for students in 2026. From budget picks under $1000 to premium workstations. Expert analysis on battery, performance, and value.">
1010
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap"
1111
rel="stylesheet">
12-
<link rel="stylesheet" href="../style.css">
12+
<link rel="stylesheet" href="../style.css?v=2">
1313
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
1414
<link rel="icon" type="image/png" sizes="32x32" href="../assets/icons/favicon-32.png">
1515
</head>

0 commit comments

Comments
 (0)