Love Fuel?    Donate

FuelPHP Forums

Ask your question about FuelPHP in the appropriate forum, or help others by answering their questions.
Assets - What is the query string at the end of the src?
  • Just like the title asks, when linking things with Asset, what is the query string at the end of the src attribute and what is it used for? Couldn't find anything in the search or docs about it. here's an example of an image linked with Asset:
    <img id="gallery-img" src="assets/product/img/large/no_img.png[b]?1328910154[/b]" alt="">
    

    Sorry if it's a dumb question.
  • It's the timestamp of the asset. Caching mechanisms take the entire URI into account. This means that your asset will be cached by the browser until you modify the asset. That will cause the timestamp to change, upon which the browser will fetch the new asset. This way you can update assets without caching problems.
  • Thanks for the answer. Makes sense.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion