WebsiteBaker Support (2.13.x) > General Help & Support

TIP - How to force new stylesheets to website visitors

<< < (2/2)

CodeALot:
Ok. I never thought of filemtime :-) (Thanks dbs :-)

So I put 2 and 2 together and now frontend.functions. php has this snippet:


--- Code: ---                      case 'css':
                          $sRetval .= "\t\t".'<link rel="stylesheet" href="'.$oReg->AppUrl.''.$sLinks.'?'.filemtime($sLinks).'" media="screen">'."\n";
                          break;

--- End code ---

forcing the visitor's browser to always read the latest CSS-version of any frontend.css.

sternchen8875:
Simple Question: Why is this not the standard in WebsiteBaker?

we found this solution everywhere in the web, its part of the description on php.net, but why is it not part of our code?  :roll:

CodeALot:

--- Quote from: sternchen8875 on February 01, 2025, 11:12:48 AM ---Simple Question: Why is this not the standard in WebsiteBaker?

we found this solution everywhere in the web, its part of the description on php.net, but why is it not part of our code?  :roll:

--- End quote ---
Well... Maybe next version? :-)

Navigation

[0] Message Index

[*] Previous page

Go to full version