Mark (a11n)
Forum Replies Created
-
Forum: Plugins
In reply to: [WP Super Cache] Is WPSupercache compatible with Wordfence.Hi @teresacuervo,
Thanks for writing in.
While I can’t really offer specific support for WordFence, to the best of my knowledge WP Super Cache and WordFence work alongside each other. I certainly haven’t seen any reports of a compatibility issue there.
If you run into any trouble, let us know!
Forum: Plugins
In reply to: [WP Super Cache] Files Could Not Be DeletedHi @logosbyls,
I’m sorry to hear you’ve had so much trouble.
WP Super Cache does not change your original site content in any way. Instead, it stores a copy of your site’s HTML code in new files which it serves to future visitors to speed up their experience of your site.
When you deactivate WP Super Cache, it no longer has any impact on how your site operates. Your original unchanged site will be served, and any cached HTML files will be deleted and/or ignored.
If your site has had an issue, and deactivating WP Super Cache did not fix it, it is very unlikely that WP Super Cache is the cause of your site’s issue.
Regarding WordPress’ warning about deleting files: This can happen if WordPress is unable to delete files from your site for any reason. When this happens, you need to access your site’s files and delete the plugin yourself.
Depending on your web hosting provider, you may be able to access your site’s files via their web interface, a cPanel interface, or an FTP/SFTP interface. However your host allows you to access your files, you can delete WP Super Cache completely by deleting the following directory from your site:
wp-content/plugins/wp-super-cache
If you need help doing so, I recommend contacting your hosting provider for help deleting the directory.
I hope that you manage to find the root cause behind your issue with block images, and that you can get on top of the problems you’ve had.
Forum: Plugins
In reply to: [WP Super Cache] wp-config.php permissions set to 600Hi @dimalifragis,
Thanks for writing in with this observation.
WP Super Cache automatically adds a couple of constants to your
wp-config.phpfile to allow it to manage your cache before WordPress has been fully loaded. It also cleans up after itself by removing those constants when you deactivate the plugin.When updating your
wp-config.phpfile, Super Cache is very careful never to leave your config file in a half-written state, so if something goes wrong it will not break your site.It updates your wp-config file by creating a copy with the necessary changes, then it renames the file to switch you to the updated configuration. In doing this, it appears to have modified your file permissions.
I have filed an issue for us to investigate a fix for this in a future release of WP Super Cache here: https://github.com/Automattic/jetpack/issues/27324
Forum: Plugins
In reply to: [WP Super Cache] Error cacheHi @noemig89,
Thank you for writing in.
Putting “<?php die(); ?>” at the top of a file is a common way to ensure that the file never gets used in an unexpected way. Super Cache uses this method on some of its cache files to ensure that users can never “run” these cached pages incorrectly.
This code appearing in your cache directory is nothing to worry about.
Have you noticed any issues visiting your site?
Forum: Plugins
In reply to: [WP Super Cache] Random pages being generatedHi @morpheus83,
By default, WP Super Cache writes your cached content to “wp-content/cache/”, not “wp-uploads”.
Can you please check your “Cache Location” setting under the “Advanced” tab in Settings > WP Super Cache? If that is set to the default (ends with “wp-content/cache”), then it is unlikely that WP Super Cache has created these additional pages.
These paths also don’t look like the cache files that WP Super Cache generates. Those typically have your domain name repeated in the path, for example: “wp-content/cache/supercache/example.com/index-https.html”.
I would recommend that you review your installed plugins and check the settings for each one.
Forum: Plugins
In reply to: [WP Super Cache] Plugin Caused Site FailureHi @rizekna,
Apologies for my late response.
I released WP Super Cache 1.9.1 after you reported the issue last week. I suspect your WordPress site has auto-updated to version 1.9.1.
Provided you have 1.9.1 installed, it should be safe to reactivate the plugin now.
Please let me know if you run into any troubles!
Forum: Plugins
In reply to: [WP Super Cache] Is it actually compatible?Hi @openrange,
In most cases, it’s better to run only one caching solution at a time. Generally running multiple caching solutions won’t make your site faster, and may cause compatibility issues across different solutions.
Which other caching plugin are you using, and what settings are you trying to apply?
Forum: Plugins
In reply to: [WP Super Cache] Plugin Caused Site FailureHi @rizekna,
Thank you for writing in about this issue.
Jetpack 11.5 was recently released, and it appears there’s a conflict between it and the way Super Cache’s “Jetpack Mobile Themes” feature was implemented.
I’ve just released a fix for Super Cache in version 1.9.1, so it should be safe to install that version.
Thanks again for letting us know about the issue you ran into.
Forum: Plugins
In reply to: [WP Super Cache] Garbage Collector running with preload?Hi again @redsector72,
Thanks! I guess you have done more debugging already 🙂
> So I can’t understand why GC runs in preload, just after preload, plus I’ve checked and the file it complains is not able to delete, exist and has just been created. Maybe sometime it is able to delete it, wasting the creation of the preload.
The Garbage Collector is designed to be “safe” to run at any time – and runs both in wp_cron, and regularly at other points throughout WP Super Cache.
prune_super_cache: did not delete file as it wasn't a directory or file and not forced to delete new file: /us/News/wp-content/cache/supercache/www.tld.com/us/news/somedir/index-https.html.gzYou’re right; this is a new file that it has decided not to delete. It’s clearly just been created in the preload, and is not expired.
In theory, this shouldn’t be a problem — unless:
> Time. I can’t understand why do you log time in UTC time, but my server is not using UTC time anywhere. My files date/time is not UTC, so maybe you’re not converting files local time to UTC when doing GC?
This is an interesting theory. Timezones are always “fun”.
The timestamps shown in your debug log are generating using PHP’s own time functions, with no explicit conversion to UTC. That suggests that your PHP settings are configured to use UTC, despite your server generally running on a different timezone.
However, WP Super Cache relies on
filemtime()to read the time files were last updated, andtime()to get the current time. Both are equally affected by PHP’s timezone setting, so they should (in theory) match.But there are a million different ways to setup a server, and I can’t rule this idea out. If we can identify which code-path in WP Super Cache is deleting these files, we can dig in further to find out more.
Have you seen any delete logs in your debug log? They would generally look line one of these:
wp_cache_phase2_clean_expired: Deleting obsolete wpcache cache+meta files: [filename] Deleting wp-cache file: [filename] Deleting supercache file: [filename] Deleting [filename], older than [time] secondsFinding these would help us identify which path the files are being deleted on; there are a few ways files can be deleted in WP Super Cache.
Forum: Plugins
In reply to: [WP Super Cache] Probable bugHi @redsector72,
Thanks for your report!
I’ve just tested
wpsc_get_realpathwith a directory with two slashes in it, and found that it works as expected. There must be more going on here.First, is your site hosted on a Windows server? I ask because Windows directory handling can be a bit different to Linux, which may explain why I’m seeing different behavior on my test site.
Second, have you double-checked that the named directory exists on your server? I know that may seem like an obvious question, but I sometimes find with particularly long directory names like these it is easy to accidentally check the wrong location.
Finally, have you had any further luck investigating why your preload filed are being wiped out? I hope your debug logs end up shedding some light on what’s going on.
Forum: Plugins
In reply to: [WP Super Cache] Disable “Delete Cache” ButtonHi @vdn-staff,
There is no official support for this. May I ask what the use-case is? Do you want to hide it from specific users?
Right now, the Delete Cache button is only shown for users with the “delete_others_posts” permission. You could use that to control who can and cannot see the button.
If you would like to just hide the button for cosmetic reasons, you could do so using some custom CSS:
#wp-admin-bar-delete-cache { display: none; }However, this will not prevent advanced users from removing the custom CSS and accessing the button.
Forum: Plugins
In reply to: [WP Super Cache] Pages/Posts Moved Permanently?Hi @myflickpov,
Regarding the message “Moved Permanently”, that message sounds far more daunting than it really is. It’s a standard signal used on the web to tell browsers / visitors to your site that its real location is different to the one they loaded.
In your case, your site’s home address starts with “https://”, not “http://”. The difference is that https is more secure and often faster, so that is the better choice. Anyone who visits your site using the “http://” address will receive a “301; Moved Permanently” signal, redirecting their browser to the correct address. This shouldn’t be a problem, and is normal behavior for a secure site.
If you use the “https://” version of your site address when running a PageSpeed report or a Caching Checker test, it won’t tell you that it was Moved Permanently.
I’ve checked both your PageSpeed Insights report, and your Browser Caching Checker results. I am happy to report that neither indicate that WP Super Cache is not working, however I understand the confusion.
PageSpeed Insights recommends “Serve static assets with an efficient cache policy”, and Browser Caching Checker has a heading with a lot of files under it labelled “Non-Cached Files”.
Both of these tests / results are referring to a specific kind of caching, called “Browser Caching”. When loading a webpage, the server can tell the browser how long to keep each resource for. For example, images don’t change very often on most sites, so many servers tell the browser to keep a copy of downloaded images for a long time so that future visits to the same page can skip downloading that image.
These warnings on PageSpeed Insights and Browser Caching Checker are both complaining that some of the images and scripts served by your site don’t have information with them about how long the Browser should cache them.
WP Super Cache is a server-side cache; it saves the results of WordPress pageloads on the server, so that multiple visitors reaching your site will load the site faster. It doesn’t tell the Browser how long to hang onto images and other static resources.
Forum: Plugins
In reply to: [WP Super Cache] Cache Contents – Super Cache (0)Hi @dickraney
Thanks for running the test for me! Looking at your logs, I can see a bunch of activity in wp-admin which we can disregard. The first non-wp-admin load in your logs is:
14:12:14 11016 / wpsc_is_caching_user_disabled: false 14:12:14 11016 / wp_cache_get_cookies_values: return: 14:12:14 11016 / supercache dir: /var/www/vhosts/mydomain.com/httpdocs/wp-content/cache/supercache/www.mydomain.com/ 14:12:14 11016 / wp-cache file exists: /var/www/vhosts/mydomain.com/httpdocs/wp-content/cache/supercache/www.mydomain.com/wp-cache-b78f00e0bf0882a258c2b125d46e642b.php 14:12:14 11016 / Serving wp-cache static file 14:12:14 11016 / Getting legacy cache file /var/www/vhosts/mydomain.com/httpdocs/wp-content/cache/supercache/www.mydomain.com/wp-cache-b78f00e0bf0882a258c2b125d46e642b.php 14:12:14 11016 / exit requestThat is rendering a cached file. That means that your cache is either not clearing correctly, or is being regenerated very quickly after you clear it.
Can you please delete your cache once more, and check if there are any files under
wp-content/cache/supercache/on your site. If so, check their permissions to make sure that WordPress can delete them.It may also be worth deleting the contents of the
wp-content/cache/supercache/directory manually (via your web hosting dashboard or FTP program) to force these “stuck” files out.Forum: Plugins
In reply to: [WP Super Cache] Plugins vs SSRHi @hassesthlm,
I’m afraid I’m not familiar with Simply Static, so I can’t comment on that plugin specifically.
However, I can describe the difference between a static site generator (like Simply Static), and a caching plugin (like WP Super Cache).
Caching plugins don’t change the way your site works. The first time a user visits any page on your site, a copy of its HTML is saved and served to the next visitors until the HTML needs to be regenerated.
Caching plugins (including WP Super Cache) can be configured to pre-generate all of the pages on your site, too – so that visitors to your site will almost always be served a quick pre-generated page.
On the other hand, site generators like Simply Static generate a whole copy of your site as a directory full of HTML files, which can be served to your users without running WordPress at all.
As a general rule, I would recommend caching for almost any WordPress site, as it can improve the performance without altering the way it works. Static pre-generation can work for some sites, but I would not recommend it for any site with e-commerce, user accounts, or dynamic content that relies on communicating with the server.
Forum: Plugins
In reply to: [WP Super Cache] preload cache with list of (dynamically created) urlsHi @insomnia88,
I’m afraid WP Super Cache focuses on the pages and posts that WordPress knows about, at their permalink URLs.
If you want to preload extra posts, you will need to use an external tool. You shouldn’t need a full headless browser; a tool like cURL should be able to trigger an appropriate HTTP request to preload any additional pages / URLs you would like.