jquery - Asset URLs without cache timestamps in Rails -
I am using a transparent PNG with the library. This fix works only on "URLs" which are "-trans." Ends in.
Railway timestamp-based caching is causing problems with this when I use image_path () to generate the URL for the image, this file's last-modified timestamp will display the image's query Adds to string. Since the URL does not end in "-trans.png" (instead there is a longer integer in "?"), Google's Javascript fails to activate.
I do not want to; On just a few pictures I also do not want to root code the hardcod to relative URL. I want to use the rail to make the URL correctly if the site is posted in root or an (unknown) subdirectory.
What options do I have?
# Sorry I stopped cuff and this code has not been run - alias_method_chain : Image_path ,: google_sense def image_path_with_google_sense (source) raw_image_path = image_path_without_google_sense (source) if source.end_with? ('- trans.png') # Time stops Raw_image_path.split ('?'). First, the second raw_image_path end and
Comments
Post a Comment