What does "main.css?v=1.5" mean?

What does "main.css?v=1.5" mean?

am 21.06.2007 12:19:38 von Eric

Hi all

Can anyone explain why some sites append query strings to their
stylesheet URLs? For example:

If you go here: http://www.lovefilm.com/visitor/home.html

You'll see:

href="http://www.lovefilm.com/lovefilm/static/css/main.css?v =1.5"
type="text/css" media="all"/>

Re: What does "main.css?v=1.5" mean?

am 21.06.2007 13:02:48 von Benjamin Niemann

Eric C. wrote:

> Can anyone explain why some sites append query strings to their
> stylesheet URLs? For example:
>
> If you go here: http://www.lovefilm.com/visitor/home.html
>
> You'll see:
>
> > href="http://www.lovefilm.com/lovefilm/static/css/main.css?v =1.5"
> type="text/css" media="all"/>

The CSS may be generated by a script and the query parameter specifies which
version of the CSS file should be used. If it is a static file though
(which the 'static' in the URL suggests), the query part is simply ignored.

Might be an artifact from a time, when the CSS was dynamically created, e.g.
a CMS which uses dynamic files for the 'development version', but exports
static files for the 'live version'.

--
Benjamin Niemann
Email: pink at odahoda dot de
WWW: http://pink.odahoda.de/