Page 1 of 1

Apache caching

PostPosted: 08. February 2016 14:46
by shortmort37
XAMPP is working beautifully for me! I copied my production phpBB board to my local computer, C:\xammp\htdocs - then loaded a database backup into MySQL. It all works flawlessly! Now I can test changes locally before I port them to production.

I'm having problems with the persistence of changes, though. If I edit a file, relaunch the page and examine the source, it corresponds to an earlier version of the file. I tried an Apache stop/start, to no avail. Is Apache caching, and if so, is there a way for me to turn that off?

Thanks
Dan

Re: Apache caching

PostPosted: 08. February 2016 16:17
by Altrea
Either phpbb defines caching or your browser.
Xampp does not define any Apache caching rules.

Re: Apache caching

PostPosted: 08. February 2016 16:29
by shortmort37
Altrea wrote:Either phpbb defines caching or your browser.
Xampp does not define any Apache caching rules.


My test code is in a subdirectory of my phpBB root, and is not known to phpBB - it's not in the phpBB cache. I've cleared by browser cache, several times.

I didn't modify anything with the standard distrib, but I know that Apache can cache: https://httpd.apache.org/docs/2.2/en/caching.html

I'm not sure how to diagnose my problem. I'm open to suggestions...

Dan

Re: Apache caching

PostPosted: 08. February 2016 18:05
by JJ_Tagy
He didn't say Apache can't, he just was saying that by default XAMPP is not set to have Apache cache. I see a few possibilities.
- Browser cache: Ensure you clear the cache with all browser windows closed. Double check processes to see if browser is still running but "hidden"
- Wrong files: Check that you are in fact editing the correct file. Maybe you have copied the files in more than one location. Verify your url is requesting the correct location.
- Source files using live: It may be that your files or database have hard coded url to live files. Check that your access log does in fact receive a call and status 200 for each time you load the page.
- Included setting: Check that you don't have a .ini or other configuration file included from the source index/settings which may override your XAMPP setup.

Re: Apache caching

PostPosted: 08. February 2016 19:07
by Nobbie
shortmort37 wrote:My test code is in a subdirectory of my phpBB root, and is not known to phpBB - it's not in the phpBB cache.


What makes you so sure about that? Maybe phpBB caches everything what is stored under the phpBB root directory (that would a typical behaviour for caching). I dont think that phpBB is working with kind of file list, it simply caches everything what is requested in a certain scope. Just to be sure: there is cache folder under phpBB, you should clean up that folder (i.e. delete all files).

Re: Apache caching

PostPosted: 09. February 2016 14:04
by shortmort37
I cleared the phpBB cache.

Same behavior.

Dan

Re: Apache caching

PostPosted: 09. February 2016 17:46
by Nobbie
Are you sure you are calling/updating the right file? There is no caching from Xampp or Apache, when i change a HTML/PHP file, i simply need to reload it in my browser to see the changes. On all servers i manage (quiet a few).

Re: Apache caching

PostPosted: 09. February 2016 18:38
by shortmort37
Nobbie wrote:Are you sure you are calling/updating the right file? There is no caching from Xampp or Apache, when i change a HTML/PHP file, i simply need to reload it in my browser to see the changes. On all servers i manage (quiet a few).


I manage two phpBB boards myself. I know all about clearing the server side cache after an update, and clearing the browser cache. And I know what I edited. I can open the very file with my edits and display it side by side with the browser "view source". They are different.

I'm new to XAMPP, so I can guess I'm doing something wrong. What I *can't* guess, is exactly what it *is* that I'm doing wrong. I wish I had a path for diagnosis.

Re: Apache caching

PostPosted: 09. February 2016 19:34
by Nobbie
shortmort37 wrote:I'm new to XAMPP, so I can guess I'm doing something wrong.


There is nothing you can do wrong in Xampp. Definately not. I dont know, what your are doing, and i dont know, what you are doing wrong. But anyway, it is not a Xampp issue.