Cleared the cache to be sure and retried... Getting '304 Not Modified' status code for local static items to be cached But '200 (from cache)' for remote items...
So seems like this has to do with localhost requesting local resources... Client side caching works perfectly online, so not an issue, but good to know... Thanks -molhokwai On Thu, Oct 17, 2013 at 1:25 AM, Dave S <snidely....@gmail.com> wrote: > > > On Wednesday, October 16, 2013 11:06:23 AM UTC-7, molhokwai wrote: >> >> Well... >> It doesn't seem to work on local dev_appserver, but it actually works, >> when deployed on appspot.com... >> So, anyway, problem solved... >> >> > Different IP or domain name? > > If your browser's cache wasn't cleared, the old copies would be retained > until the original expiration had passed, so you wouldn't see the new > copies. By changing "machines", you may have been unrecognized as "already > cached". > > I learned a little about this stuff in connection with the Web2Py IDE > ("blank screen in editor") > > /dps > > On Wed, Oct 16, 2013 at 4:14 PM, molhokwai <molh...@gmail.com> wrote: >> >>> Hi, >>> >>> I've tried changing client side caching headers expires or cache-control >>> value (from 10mns by default?), running the code below from the >>> corresponding controller, but the values are unaffected. >>> >>> import datetime >>> expires = datetime.datetime.now()+datetime.timedelta(0,365*24* >>> 3600) >>> # ex: Fri, 01 Jan 1990 00:00:00 GMT >>> response.headers['Expires'] = expires.strftime("%a, %d %b %Y >>> %H:%M:%S GMT") >>> response.headers['Cache-Control'] = >>> 'public,max-age:%i,must-revalidate' % (365*24*3600) >>> >>> >>> How should this be done? >>> >>> Thanks >>> -molhokwai >>> -- >>> Resources: >>> - http://web2py.com >>> - http://web2py.com/book (Documentation) >>> - http://github.com/web2py/web2py (Source code) >>> - https://code.google.com/p/web2py/issues/list (Report Issues) >>> --- >>> You received this message because you are subscribed to a topic in the >>> Google Groups "web2py-users" group. >>> To unsubscribe from this topic, visit >>> https://groups.google.com/d/topic/web2py/BMxhOL_X2y8/unsubscribe. >>> To unsubscribe from this group and all its topics, send an email to >>> web2py+un...@googlegroups.com. >>> >>> For more options, visit https://groups.google.com/groups/opt_out. >>> >> >> >> >> -- >> >> ------------------------------------------------------------------------------------------------------------- >> *M*T, *M*olhokwai >> *+32 489 33 71 51, molh...@gmail.com, chat/voip(gtalk):molhokwai* >> * >> * >> Don DeLillo: Underworld | Don DeLillo: Cosmopolis | The Matrix: The >> Architect | Brandford Marsalis: Mr J.C. >> (Live) | Ursula K. LeGuin: The Dispossessed | Annares | Robert Zemeckis: >> Contact | What the *bleep* do we >> know... | E.J. Strickland: In this Day | Jeff Buckley: Grace | Qawalis >> | Genesis: FoxTrot | XXX | Artémise & >> Mausole | XXX | Le Taj Mahal | Slow | Infinity | Khalasa | Google >> | Coltrane | X-Men III: The Phoenix | RATM | >> Jean D'ormesson: Le Juif Errant | Les Quatre Incommensurables | Edgar >> Allan Poe: Ms found in a bottle | 7 | >> Georges Clooney: Confession of a dangerous Mind | The hand of God | >> Dreaming Bear Kanaan | >> Implementing change | Amin Maalouf: Le Rocher de Tanios | 9 | The Grand >> Cycle | The Beyonder | The >> Venus Project | Patrick Suskind: Le Parfum | Ethan & Lucas Vorly | >> Khaili Gibran: On Love | >> Urbanfarming.org | Planck's Constant | Gemineye: Poetic bloodline | >> Moving-planet.org | 350.org | Bree >> Olson | Jacques Audiard: Sur mes lèvres | Raymond Devos | Terrence Mc >> Kenna | Alan Watts | Mindwalk: >> Liv Ullman's Sophia Hoffman | ... >> >> *Let's talk* >> >> -- > Resources: > - http://web2py.com > - http://web2py.com/book (Documentation) > - http://github.com/web2py/web2py (Source code) > - https://code.google.com/p/web2py/issues/list (Report Issues) > --- > You received this message because you are subscribed to a topic in the > Google Groups "web2py-users" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/web2py/BMxhOL_X2y8/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > web2py+unsubscr...@googlegroups.com. > For more options, visit https://groups.google.com/groups/opt_out. > -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.