Jump to content

Recommended Posts

Posted

hi 

I have observed that processwire always cache my page even if i have disable cache from template, 

my problem is that trying to style the page and to be able to see my changes i have to clear the cache either by save the page again or delete the assets/cache/* or  inside module page render .

i have try  processwire v 3.0.39, 3.042, 3.051 

thanks 

Posted

Hi kongondo, 

im working local (MAMP), i have try with chrome and safari, also i access the page through local network from another pc and the first time load is getting the right data and after that return from cache, 

cant be sure about browser cache i will test it more. though  every time i clear the cache pages from assets/cache processwire recreate them,  don' t know if that matters.

thanks for your response

Posted

When it comes to styles, my bet's on browser cache. If you want Chrome to fetch assets from the server, leave the dev console open as you develop, or develop in an incognito tab. From what I know, ProcessWire does not cache anything in the frontend unless you implemented that yourself, e.g. MarkupCache, etc.

  • Like 1
Posted

its not only styles, is also simple html code or just dummy text (screenshot)

looks like it auto clear cache every 3-5 minutes ???

 

Screen Shot 2017-01-31 at 13.57.53.png

Posted (edited)

I see. I am not seeing that at all in my tests. Looks like a Markup or Field or most likely Template cache. Are you sure you did not accidentally enable cache for the template that page uses? See Cache Tab when editing the said template.

Edited by kongondo
Posted (edited)

Is this happening for all pages (i.e. for different templates) and all fields (i.e. title versus body fields, etc)?

Edit: Just notice you said you are using $p->render()? Can you show us some code?

Edited by kongondo
code request
Posted

i have test two templates and its the same, 

if change some field and press the save button cache is cleared and return the new value.  

Posted (edited)

I am a bit confused. Isn't that the expected behaviour? You change a value, you save, then you see the new value? Please also see my edit in the post above yours.

Edited by kongondo
Posted

no $p->render() just dummy html 

from processwire view thats right you save your content and its been update but im making html changes or writing some simple php code like  <?php echo time(); ?> foreach loops e.c and it doesnt show my modified code unless save the current page or manually clear the cache. 

 

Posted

I get you now. You are making changes in the template file and those are not being reflected in the frontend unless the cache is cleared, right? Let me test that.

Posted

Everything works as expected here. Changes made in the template file are reflected immediately when I reload the browser, whether I am logged in or not. I have tested in PW 3.0.42. Maybe some MAMP thing?

  • Like 1
Posted (edited)

Excellent! Glad you got it working. 

Edit: If you can mark this as solved then, by editing the title of this thread to [Solved]....rest of title...

Edited by kongondo
  • Like 2

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...