I know this question has been asked multiple times before, but the solutions posted are not working for me.
I have put the following in the <head> tag, to no avail:
<meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate">
<meta http-equiv="Pragma" content="no-cache">
<meta http-equiv="Expires" content="-1">
I also saw some mention about the onunload attribute and the bfcache in browsers, so I added that to the <body> tag, also to no avail.
The response headers from my server contain:
Cache-Control max-age=0, private, must-revalidate
Would appreciate it if someone could point me in the right direction here – what am I doing wrong?
Answering my own question. As it turns out, setting the following response headers (as opposed to
METAtags) worked for me:If you’re working in Rails like I am, you can do this easily by putting the following in an
ApplicationControllerbefore_filtercallback: