Knowledge on .NET Development, iPhone App Development, Android App Development, SQL Server, and everything related Computer Science
Tuesday, May 31, 2016
Thursday, May 26, 2016
Force Client to Download new resource files
Code behind
//add the version number to the css and js link
string host = Request.Url.Host;
if (host.ToLower().IndexOf("dev") > 0 || host.ToLower().IndexOf("test") > 0)
{
Random rnd = new Random();
version = rnd.Next().ToString();
}
else {
version = ConfigurationSettings.AppSettings["app_version"];
}
https://www.iis.net/configreference/system.webserver/staticcontent/clientcache
Subscribe to:
Posts (Atom)