Please refer - http://web.guru99.com/perl-subroutines/ I am calling the file http://code.guru99.com/perl/perl.js inside the corresponding wordpress post.
The file is 750KB in size I am using WP Super cache but it does not cache or compress this file (maybe since it’s called in the post section).
How can I compress and cache this file before serving to the end user ?
if an apache server you can enable mod_gzip or mod_deflate in .htaccess for this filetype something like the codescrap below, which zips the most zippable filetypes
cache can be set in .htaaccess as well using mod_expires, the instructional search is left to the user, because I dont have the code stuck in my head for that
edit: reread the post,
it is considered improper to serve a file located on someone else's server as part of your system unless the other person explicity agrees and offers that service. eg google script, because that third party has to pay the banmdwidth costs, it is considered theft. likewise pinching the code itself is considered theft of intellectual property
the code above only works if the file is hosted on your site
if the author permits, place it on your host, and serve it from there with the appropriate attribution,
I think mod_deflate / mod_gzip is a better suggestion
mod_gzip_item_include file .(html?|txt|css|js|php|pl)$
compresses all the filetypes listed, served from the server
http://code.guru99.com/perl/perl.js is my site :)
I think I have found the issue! No need to htaccess changes
The problem is files are being appended with “?fe74d6”
for example http://web.guru99.com/wp-content/uploads/dynamic_avia/enfold.css?fe74d6
I am not sure where and how this “?fe74d6” comes from!
I am using wordpress for my site and have W3Total cache installed , which is able to gzip the files without “?fe74d6”
Can you guys help ?
I apologise for jumping to conclusions
it happens too often, and I just expected it.
I clicked view source, the parameter has to be added somewhere, perhaps in the wordpress plugins being used, just about everything in the page <head> has had the parameter added if it isnt in the source, something has to be doing it in the serverside scripts