Files
studiobeve.no/application/views/includes/barber-head.php
T
UbuntuandClaude Opus 5 7f51a795a5 Cache-bust local css/js so a deploy is picked up immediately
Apache serves this site's static files with only Last-Modified/ETag and no
Cache-Control or Expires, so browsers apply heuristic freshness and can hold
a stale stylesheet for hours. Deploys here are a file copy, so nothing else
signals a change. During development this masked CSS edits three separate
times; on the live site a returning customer would keep the old stylesheet
after a deploy with no way to know.

Adds asset_ver() (autoloaded), which returns the asset URL with the file's
mtime appended, so the URL itself changes whenever the file does. Falls back
to the plain URL when the file is missing, so a bad path degrades to the
previous behaviour rather than warning.

All 54 local css/js links now route through it, across the four *-head.php
and four *-skeleton-bottom.php includes.

Notes
- Remote assets are deliberately untouched: Google Fonts, momentjs,
  cookieyes and the googleapis jQuery keep their own URLs. Only files inside
  the webroot are versioned.
- vertical-head.php has one dynamic path (assets/css/<?= $vertical['css'] ?>)
  which is special-cased; a generic rewrite would swallow the nested <?php.
- Images are NOT versioned. Replacing an image under the same filename can
  still serve stale.
- head.php is shared by the public home page and the whole admin portal;
  /login verified to still render with versioned CSS.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-15 09:00:40 +00:00

48 lines
3.6 KiB
PHP
Executable File
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<?php
$this->load->helper('url');
?>
<head>
<!-- Google Tag Manager -->
<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
})(window,document,'script','dataLayer','GTM-TWRHH7DN');</script>
<!-- End Google Tag Manager -->
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Studio Beve - Beauty & Barber Shop</title>
<meta charset="utf-8" />
<meta property="fb:app_id" content="285150047390571" />
<meta property="og:site_name" content="Studio Beve Barber">
<meta property="og:image" content="<?php echo SITEURL?>assets/img/studiobeve_facebook.jpg"/>
<meta property="og:title" content="Studio Beve" />
<meta property="og:description" content="Vippestylist, make up artist, PMU-artist" />
<meta property="og:url" content="<?php echo SITEURL;?>/barber" />
<meta property="og:type" content="website" />
<meta name="description" content="Skjeggtrimming, Barneklipp, Skjeggfarging, Herreklipp, Skinfade Herreklipp, Voks, Beard Trimming, Child Haircut, Beard Dying, Traditional Shave, Men's Haircut, Skinfade, Wax, herrefrisør, Trondheim, hårklipp, haircut, barber, barberer, Men’s hairdresser">
<link rel="icon" type="image/x-icon" href="<?php echo base_url();?>assets/img/favicon/favicon.ico" />
<link rel="icon" type="image/png" href="<?php echo base_url();?>assets/img/favicon/favicon.png" />
<link rel="icon" type="image/gif" href="<?php echo base_url();?>assets/img/favicon/favicon.gif" />
<!-- Opera Speed Dial Favicon -->
<link rel="icon" type="image/png" href="<?php echo base_url();?>assets/img/favicon/speeddial-160px.png" />
<!-- For iPhone 4 Retina display: -->
<link rel="apple-touch-icon-precomposed" sizes="114x114" href="<?php echo base_url();?>assets/img/favicon/apple-touch-icon-114x114-precomposed.png">
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
<link rel="stylesheet" href="<?php echo asset_ver('assets/css/barber.css');?>" />
<noscript><link rel="stylesheet" href="<?php echo asset_ver('assets/css/noscript.css');?>" /></noscript>
<link href="https://fonts.googleapis.com/css?family=Open+Sans" rel="stylesheet">
<!--<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>-->
<link href="https://fonts.googleapis.com/css2?family=Abril+Fatface&family=Open+Sans:ital,wght@0,700;0,800;1,700;1,800&display=swap" rel="stylesheet">
<script src="<?php echo asset_ver('assets/js/jquery/jquery.js');?>"></script>
<link rel="stylesheet" href="<?php echo asset_ver('assets/js/jquery/jquery-ui.css');?>">
<script src="<?php echo asset_ver('assets/js/jquery/jquery-ui.js');?>"></script>
<script src="https://momentjs.com/downloads/moment-with-locales.js"></script>
<!-- Start cookieyes banner --> <script id="cookieyes" type="text/javascript" src="https://cdn-cookieyes.com/client_data/82ccb0b38ad63612e4c6a3fa/script.js"></script> <!-- End cookieyes banner -->
<link rel="stylesheet" type="text/css" href="<?php echo asset_ver('assets/css/style.css');?>">
<link rel="stylesheet" type="text/css" href="<?php echo asset_ver('assets/css/responsive.css');?>">
<script src="<?php echo asset_ver('assets/js/script.js');?>"></script>
</head>