IE Cache Problem

Sep 5, 2006

i'm having some issues with pages that IE don't reload, the problem is that i have other similar sites that don't present that problem, any one know what causes it, and how to fixit.

Actualy i'm petched it adding a ?stamp=".date("YmdHis") on every link. I't working fine, but if it's posible i want to find some more proper fix.


Caching - Implementing Cache With Maximum Size Of Cache Folder?

Jul 2, 2010

I need to implement cache for my PHP web application. I implemented the cache file control (saving and getting files from cache dir) but now I need to enforce cache folder max size control, because cache folder should be limited in max size.I had an idea to limit the size by deleting the least used files when the space is needed. Now, I've read that using the fileatime function on all the files in cache dir would slow down my application.Is there any other method that springs in your mind?

(DB (MySQL) usage for storing last access time for cache files is, unfortunately, unimplementable.)

View 1 Replies View Related

APC: Opcode Cache Versus User Cache - Set Separate Limits?

Oct 10, 2010

I am trying to move from the typical combination of APC (for opcode) and Memcache (for my userdata) to a purely apc based cache. Given my usage structure it makes sense and performance is higher. But unlike before, where the apc cache was limited to a reasonable size and did not affect my data cache, I am now worried that the opcode cache might grow relatively large so that the sum of opcode cache an datacache exceeds the limit. As far as I understand, this would result in a flush of the total cache.Is there a way to mimic the behaviour, as if apc was only an opcode cache and limit the opcode cache size to a reasonable limit, leaving the rest for user data? Or should I try setting lower ttl values for the opcode cache, so it always gets flushed first?

View 1 Replies View Related

Zend Cache Core And APC - How Old Cache Entries Get Invalidated?

Oct 10, 2009

For Zend_Cache_Frontend_Core you can define a lifetime and, according to the documentation, a "automatic_cleaning_factor".According to the manual, this property specifies on how many writes to the cache old cache entries get invalid.When I use APC as backend shouldn't the cache invalidate itself automatically without having to write to the cache?Or did I misunderstand something there?

View 1 Replies View Related

[ezSQL Cache] Deleting Specific Cache Files

Jun 2, 2011

As you know, ezSql has a useful caching feature. I'm newly using this but when i edit anything on database, i'm deleting all cached files, and waiting for caching them again. I'll explain it with an example, There is a page ([URL]) which listing user's datas (username, city, phone etc..) .

I'm caching all queries on user.php file and all users' datas caching seperately. When some user (John) update own datas. When this happened, i'm deleting all cache files, so i'm deleting all user's cached datas. Are there any way to deleted (or refresh) only John's datas cache? What do you think, is it possible ? You know cache files names is hashed (like this: 6f3b84011a8693ad7e5b86c6dff3d27d )

View 1 Replies View Related

Use Application Cache In Combination With Page Cache?

Aug 26, 2010

Do we get any undesired results when we use application cache in combination with page cache in php?

View 1 Replies View Related

How To Cache A File Into Client's Cache?

Apr 18, 2007

My site is a bit slow and I wonder if I can explicitly cache A file (image) into client's cache (temporary files).

View 3 Replies View Related

Why Is APC Incrementing "Cache Full Count" For User Cache Even Though It Has Plenty Of Memory Available

Jul 28, 2010

I've played with this for quite a while but am at a bit of a loss as to what to do. I'm using APC 3.1.3p1 on CentOs 5 with PHP 5.2.5. APC is acting as both the opcode cache and user cache. Mostly this server runs Drupal 6 sites using the CacheRouter module for APC cache support. I was running APC 3.0.19 for a while but it was causing Apache to lock up occasionally (a documented bug in that version of APC) so that's why I'm on 3.1.3p1. I've configured APC to have 512 MBytes of memory (mmap). The symptoms are a little intermittent but starting from an empty cache this is generally what I see:

The user cache fills rather slowly. Despite an initial insert rate of something like 20,000 inserts/sec, the user cache will only report a few hundred, then a few thousand entries, and will grow very slowly. I can possibly attribute this to write_locking being on but just want to mention it in case it's of importance in solving the problem at hand. After several hours it hits an equilibrium of around 30k entries. Fragmentation sets in early and grows quickly. Within maybe 10 hours or so I'm usually at 100% fragmentation.
Overall (opcode + user) cache usage stabilizes around 240MB or so. It will virtually never go above that level. After a day or so I'll start seeing the User Cache Cache Full Count (UCCFC) incrementing.

At the time of this writing my UCCFC is at 62358 and growing despite APC reporting 280MB free. I have a user_ttl of 7200, but I've also played with setting it to 0 or other amounts and it has little to no effect on the problem. I suspect the problem has something to do with fragmentation. Right now my server is reporting "Fragmentation: 100.00% (280.0 MBytes out of 280.0 MBytes in 24740 fragments)" and 280 MB just so happens to be the amount of free space APC is reporting; a telling coincidence, I think. Unfortunately, I've found precious little information in the docs or elsewhere to indicate just what "fragmentation" truly means in the APC world, and there seems to be virtually nothing you can do to avoid it.

View 2 Replies View Related

Header("Cache-Control: No-cache, Must-revalidate");

Mar 6, 2007

header("Cache-Control: no-cache, must-revalidate");
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");

When should I use the above on my website?

View 2 Replies View Related

Session Cache Limiter - Warning: Session_start(): Cannot Send Session Cache Limiter - Headers Already Sent

Jul 22, 2005

I was paying with my code and put in a couple of lines that did not ok I changed my mind just cut off the new lines so in a way the rest of the code was never touched but I keep getting this error over and over ...and nothing has changed it workrd just fine before. So what is that?

Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /home/public_html/search.php:2) in /home/public_html/conn.php on line 36

View 2 Replies View Related

PDF Cache

Jun 27, 2007

I have a small script which generates a PDF, but when I generate it, then change some information and generate it again the old PDF keeps showing due to it being cached.

View 1 Replies View Related


Jan 23, 2006


Person logs into website to place an order - adds a couple products to their cart... then adds another item... but all previous items are gone - just the newest item is there. I've figured out this issue, and all the items are in the database, but for some reason, a new session ID was generated along the way. When that happens, the customer thinks they lost the items in their cart.

I have only been able to recreate this issue with IE, but... 98% of our customers use IE.


Customer Logs in as USER1... browses around. Then logs out and logs in as USER2... but the site is still showing as USER1 (at the top of each page it says "Welcome USER1").... BUT, if the person holds their Ctrl+Refresh (to force a Refresh in IE) - it will show them what they should see "Welcome USER2".

Both issues are extremely frustrating and I cannot find the cause. Below is some info I'm hoping someone can look @ and recognize the problem.

session.cache_limiter = private_no_expire

(On every page I have the following bits of the order provided, but with other code left out of course.)

header("Cache-Control: no-store, no-cache, must-revalidate");
header ("Pragma: no-cache");

$SID = session_id();
$REFERRAL_URL = $referring_url;

View 1 Replies View Related


Apr 24, 2007

I used the php header and no-cache, but why it works on some computer, and not on some computer? Is there a way to fix this problem? I would like the random image to change every time of refresh or F5.

View 1 Replies View Related

APC Cache

Jul 4, 2006

My figures are:

Request Rate3.70 cache requests/second
Time To Live0
Shared Memory1 Segment(s) with 32.0 MBytes
Cache full count0.

View 1 Replies View Related

To Cache Or Not To Cache?

Aug 27, 2007

When dealing with a large amount of pages, is it better to dynamically create from the database then cache each page in a folder, or to dynamically create it using info from a database every time someone access's the page?

View 1 Replies View Related

Skipping Cache

Feb 2, 2001

I'm working on an e-com. store and the client wants it so that after you checkout if you hit the back button it skips all the previous pages in the cart and takes you back to page before you enter the cart. From what I've read it seems like I can force a page to not cache but I don't want the pages in the history at all... is there a way to do this?

View 3 Replies View Related

Headers Using No-cache

Jun 7, 2002

Have some problems with a php image updating in a page of mine. In both i have a header like so..

header ("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
header ("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
header ("Cache-Control: no-cache, must-revalidate");
header ("Pragma: no-cache");

which should be making sure the image is remade as opposed to taking it from the cache however it seems to be a bit random, sometimes it does, it sometimes it does'nt..

View 6 Replies View Related

Loss Of Cache

Oct 29, 2002

I have a little script that takes the data from a user filled-in form, and then generates a pdf file with the content. Between the actual filling in of the form and the generation of the pdf file, there is a confirmation screen where the user sees the values he/she is submitting and confirms wether they are right or not.

The problem is that if they spot an error and go back to the form (using the back button), they get a message saying that the page contains POSTDATA that has expired from cache etc... and when they get the form back, it is blank.

View 4 Replies View Related

Cache Busting

Nov 23, 2005

I have the need to prevent user caching on particular pages. I've read the manual pages on header and session_cache_limiter.

Am I right to think that these snippets are ALL that I need to reliably prevent users from caching the pages?

When using sessions:

When not using sessions:
header("Cache-Control: no-cache, must-revalidate");
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");

I don't understand the comments on those manual pages about sending a dozen different headers. Are they all necessary? Or are they legacy hacks?

View 1 Replies View Related

PHP W/ Caché Database

Sep 25, 2003

How I connect PHP on Caché Database? I'm using Windows/Apache.

View 4 Replies View Related

Cache Issue

Mar 4, 2006

All of my PHP pages have a default of no-cache. But for a specific page, I need to have cache available. I am using:


But the pages will not get refreshed with new visits even after several days, or even with Refresh. (however on IE, CTRL+F5 would bring the updated page). Do you have any idea on what I am missing. Here is the returned header for that page:

Result code: 200 (OK / OK)
Date: Sat, 04 Mar 2006 12:37:58 GMT
Server: Apache/1.3.33 (Unix) mod_tsunami/3.0
Cache-Control: private, max-age=60, pre-check=60
Expires: Thu, 19 Nov 1981 08:52:00 GMT
X-Powered-By: PHP/4.3.2
Set-Cookie: PHPSESSID=95817bf8b4d7eb3435797b2fd9f09636; path=/
Last-Modified: Tue, 21 Feb 2006 07:43:07 GMT
Content-Type: text/html
X-Cache: MISS from
Proxy-Connection: close

View 1 Replies View Related

LRU Cache Implementation

Jul 17, 2005

Most of my application's operations (including SQL queries and numerical
computation) can be cached. An LRU (least recently used) cache would fit
the bill perfectly.

This LRU cache should be preserved over multiple requests from the same
session. If possible, it should be seen across multiple sessions so that
all users can benefit from it.

I can't implement either solution. In principle I could preserve the
cache across multiple requests by using $_SESSION, but I don't think
this would be wise. The whole structure would weigh on the order of a
MB, so access would probably be really, really slow.

Also consider that access to the cache must be serialized.

I could in principle write the C code to do the caching. But this would
be extremely ugly since I want to cache PHP objects, not C structures.
There would also be the overhead of converting to and from PHP's

View 5 Replies View Related

How To Clear Cache

Jul 17, 2005

I have a php file which will list the pending
task for each developer. If the developer
changes some thing it will update to database.
Once the user clicks the update button it shows
the another page and there will be button back to
list of pending task. It will again fetch from database.

At the second time if user update some other data. It giving
me the old data list also.

I used ClearStatCache() this is not working. And also I added

<META HTTP-EQUIV="Pragma" CONTENT="no-cache">
<META HTTP-EQUIV="expires" CONTENT="0"> in my php file.

View 2 Replies View Related

No-cache With Images

Dec 27, 2001

I have a page that creates an image with imagePNG function and saves it to disk. Beside the image, there is also a form on the page, in which you can change the imagage data. When an user submits the form, then the same page is called, and the different image should be displayed (with the same name). Problem : the image stays the same, the image file changes ; PHP Code:

View 2 Replies View Related

Cache Problemette

Jul 17, 2005

I am trying to prevent a browser going back to a logon screen and any user
being able to refresh (and the browser re-submits the post data).

I understand that the following should work. It doesn't.

header("Cache-Control: no-cache, must-revalidate");
header("Pragma: no-cache");
header("Expires: Mon,26 Jul 1997 05:00:00 GMT");
I am inserting the code before any output.

View 3 Replies View Related

Crazy Cache !!

Nov 22, 2005

I've a page where I can upload and delete images.

I've such problem I'm trying to solve. My images are numbered xxxx-1.jpg,
xxxx-2.jpg, xxxx-3.jpg (where xxxx is the article number).

Now, when the used deletes the 2nd pictures, then I update the database for
having the xxxx-3.jpg renamed in xxxx-2.jpg and also I rename the file on
the server.

Problem: if I go to the article page, then the OLD xxxx-2.jpg is shown. I've
to refresh with CTRL pushed to get the correct image. Also if I come back to
manage those pictures again, then the third is definetively removed, and the
xxxx-2.jpg shown the old one, not the xxxx-3.jpg renamed.

How to avoid the server to store such think ? I don't want the cache for
such pictures.

View 12 Replies View Related

No-cache Header

Sep 2, 2003

I want to keep Proxie Servers and the Browser Cache from storing my page - to provide always a new version. I didn't have any success with meta HTTP-EQUIV tags, now I want to try it with PHP headers. Does the following code work?: PHP Code:

View 3 Replies View Related

Cookie Is In A Cache?

Aug 23, 2005

I'm setting a cookie with setcookie, and as long as I'm not closing the
browser - the cookie is kept and passed to the next page.

But as soon as I leave the site or close the browser, the cookie is
gone, ans there is nothing in $_COOKIE dor the next time.

The cookie is not shown in the cookies folder.

This is the command I use:
setcookie ('lang', $lang, 77000);

View 7 Replies View Related

Cache And Referer

Aug 18, 2002

if we click on back on this browser, this forum somehow refreshes itself. So I assume it uses something like cache. But what about sometimes, like we're filling up a form and click on submit than later realize we miss out something and this time when we click back, we get a "Warning, page had expired". So is this also using cache? If this two is the same case, how come this forum won't get affected by the expired page?

For the HTTP_Referer, I'm sorry but can anyone show some example like how do we stick this function to remember every part of the click on our site link like this forum?

I'm really desperate to know this answer and hope someone could just briefly go through these two functions to me (rather than send me to or any site) I don't mean to repeat this and hope no one will get offended by this post. I just need a little explaination.

View 9 Replies View Related

Cache Control

May 14, 2001

How can i cache a page in Php3?

View 1 Replies View Related

Browser Cache

Aug 20, 2000

I'm working on an 'e-commerce-like' site, where users can look at catalogs, look at items description, and put items in shopping carts. Most of my pages are dynamically generated (using PHP4), with the contents pulled from a MySQL database.

The problem is, for example, from the catalog page I click on an item to see more detailed description (which is also dynamically generated). But then, if I want to go back to the catalog page by clicking the browser's Back button, I'll get a page saying that the page that I wanted has expired or no longer available.

View 2 Replies View Related

Query Cache

Jul 8, 2006

I have a table where one of the columns is a view counter and therefore change at every request. If I select all columns but the view counter will my query still be able to take advantage of the query cache (other columns won't change) ?

View 1 Replies View Related

Header( ) And Cache

Apr 10, 2004

I am just made aware of the effect of Header( )and page caching for PHP pages. It seems that my pages are not being cached because I was furnishing no information in a header. A couple of hours searching led me mostly to folks that want to prevent caching in certain cases. It all seems rather confusing, and I'm hoping that out there somewhere is a generic Header( )set up that will allow my CSS file to be cached in the users browser.

View 1 Replies View Related

Alternative PHP Cache

Aug 14, 2006

I have PHP 4.4.3 and APC 3.0.11 installed. I can see APC in the PHPInfo() information and I can run apc.php, but I never see anything other that apc.php in the System Cache Entries list. I also have stat turned on so that it automatically checks for modified scripts incase they need to be reloaded. If I call apc_cache_info() from any of my scripts it shows my page and all of it's includes properly, but the number of hits is always 0. The base apc_chace_info() looks like this:

[num_slots] =2000
[ttl] =0
[num_hits] =0
[num_misses] =8
[start_time] =1155584676
[expunges] =0
[mem_size] =826296
[num_entries] =8

Do I need to set privilages to a directory, that maybe it's failing when writing to?

View 1 Replies View Related

Controlling Cache

Jul 20, 2006

I'm working on a page that uploads an image and saves it to a static filename. The page then displays the image. Due to caching, the image will not update until I force it to with a refresh. I've been trying to get the following code to keep the image from caching:

header("Cache-Control: no-cache, must-revalidate"); // HTTP/1.1
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); // Date in the past

This works about 75% of the time, but occasionally the image does not update. I'm using Firefox with no other caching helper apps installed.

View 5 Replies View Related

Clear Cache - COM

Jun 25, 2007

Is there any way to clear Internet Explorers cache using the COM object?

I am running a screen scraping script to generate thumbnails of my templates, but sometimes the thumbs get duplicated.

PHP Code: ....

View 1 Replies View Related

Cache Pages

Dec 20, 2004

I have seen some solutions but want to get the latest opinions to make sure I don't use a out of date method.

I have a large section of my website that is created using php/mysql. Some pages require multiple queries to the database. This section of my website is entirely static, besides the occassional update.

It only makes sense that I should cache these pages and deliver them as static pages. Is there a built in method in php to do this? I am on a shared server and am limited on what I can use to do this.

On the flip side, am I really taxing the server by making these queries or is it not really a big deal these days. For example, my pages are very simple next to the complexity of phpbb. Even my worst script only calls about 10 times to the database to pull the information for the page.

View 1 Replies View Related

Cache / Buffering

Oct 4, 2005

phpinfo() on my host shows
output_buffering=no value
output_handler no value no value

I assume that means it isn't available. I tried using obstart() with a long query and it didn't give an error, but the benchmark was twice as slow. I would really like to compress my files and I'm unable to find a way to do some sort of gzip locally and then upload them, that possible? I read that some browsers won't support compression, but are they referring to on-the-fly or in general?

I'm also having no luck with caching. So far all of the tutorials and articles I've read about caching involved 3rd party server installs like Smarty. Isn't there a way to just have a cron run hourly and create a snapshot of the output to browser (like view source) and overwrite the existing php page? Or maybe have index.php start out with include('dynamic_content_houry'.php')..?

View 2 Replies View Related

XML File Cache

Aug 17, 2006

Please can somebody advise me on the following:

Is it possible to use PHP to schedule my webserver to fetch XML files from various external URL's and overwrite them in a designated directory? I don't want to change the format of the xml file, just automatically update it on my server everyday.

Is this possible?

If yes, can anybody suggest any script or offer some advice on how to create my own - TIA.

View 7 Replies View Related

APC Cache Performance

Aug 22, 2006

I have tested APC cache on my server with strange results.

I have analysed my statistics and seen which pages are more requested. And I have used Junit to load test the pages, both with and without APC cache, requesting the same set of pages 500 times.

The results have not been good. Apparently in many cases the performance of PHP with APC cache are lower than standalone PHP.

Anyone had similar experiences?

View 3 Replies View Related

Best Way To Cache Php Scripts

Jul 1, 2005

If you have a site that has semi-permanent content (i.e. changes about 2-3 times per year), but would like to minimize mysql usage, i've gathered that php caching is the way to go - is this correct?

and if this is correct, it seems there are several solutions to do this? which is the best? i've come across ioncube - does anyone have recomendations or words of warning? is this something i just ask our host to install and presto, our pages are cached?

View 1 Replies View Related

Cache & Header

Feb 24, 2004

At the very top of my PHP script I have:

header("Cache-Control: no-cache, must-revalidate");
header("Pragma: no-cache");

However, IE doesn't seem to care :(
It still caches the pages... Any idea what might be wrong?

Normally I would put all this in .htaccess, but the @$%# who initially installed Apache compiled PHP/Perl/MySQL etc as dependencies of Apache, instead of loading them as modules. And, neither mod_expires nor mod_headers were compiled with Apache. So, if I wanted to either mod_, I would have to recompile not only Apache but also MySQL/PHP/Perl... (as far as I can tell). Either way, I'm not in the mood to recompile Apache at all :)

So, the reason why the PHP headers are failing -- is that related to the absence of mod_expires or mod_headers? Is there anything I can do to get the browser to not cache the page?

View 1 Replies View Related

Preventing Cache

May 24, 2007

I am trying to force the back-button to re-load a page in IE, but even the following basic script, based on, is not working:

header("Cache-Control: no-cache, must-revalidate"); // HTTP/1.1
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); // Date in the past

$timenow = time();
echo date("r",$timenow);

Am I missing something very basic here?

View 2 Replies View Related

Clear Cache?..

Nov 4, 2006

I have a script that updates an image but saves it with the exact same name. When I retun back to a page that displays the image, it shows the old one untill I refresh the page.

Is there a way to clear the cache before I get back to the page, perhaps on the pge that processes the update?..

View 5 Replies View Related

Cache A PHP Page

Aug 23, 2004

I am developing a site in PHP, but I would like the output pages to be static with different names for SEO purposes. Ex:

Going from this: /catalog.php?sectionid=1&section=men&id=5&brand=&brand=40

To this: /category/product.php or html

Thanks in advance for any help!

View 1 Replies View Related