lundi 18 janvier 2016

Rails Add timestamp with image URL in jquery blueImp image upload

I am using jQuery blueimp image upload in my rails application,I added the image called "wood.png" and saved, I deleted the image and added new image with same name called "wood.png"

It shows the preview of existing image the one I deleted. I think that I have to add timestamp in image URL.

 <td class="preview" style="width:90px;">{% if (file) { %}
      <a href="{%=file.url%}" title="{%=file.name%}" rel="gallery" download="{%=file.name%}"><img src="{%=file.url%}" style="height:70px;width:70px;"></a>
      {% } %}</td>

Can anyone help me to solve this.

Aucun commentaire:

Enregistrer un commentaire