Route with timestamp - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5) +--- Forum: General Help (https://forum.codeigniter.com/forumdisplay.php?fid=24) +--- Thread: Route with timestamp (/showthread.php?tid=68864) |
Route with timestamp - jorrik9 - 09-05-2017 Hi, I need a way to prevent a page from getting cached, so I added a timestamp to the url like this: Code: echo '<li>' . anchor('/account/?_='. time(), 'My Account', array('class'=>'leaf last')) . '</li>'; This gives a link like: /account/?_=1504635140 The route looks like this: Code: $route['account'] = 'account'; This doesn't work because it results in a nginx 404 Page not found. Any idea how to get this working? |