Questions tagged [cache]

A cache is a component that transparently stores data so that future requests for that data can be served faster. The data that is stored within a cache might be values that have been computed earlier or duplicates of original values that are stored elsewhere.

Filter by
Sorted by
Tagged with
1
vote
1answer
489 views

Clearing cached plugin data if it is using an external object cache

I have created a plugin that caches some of the data it uses - mainly Salesforce REST API call results, and expires them at intervals (by default every 24 hours). The plugin calls these methods to ...
1
vote
1answer
2k views

How can I cache WordPress Rest API Response

I'm using WordPress rest API for developing my Android application. But I can not cache the response. How can I add required headers to REST API response so that my app can save the response for ...
0
votes
2answers
84 views

WordPress website not showing changes without clearing cache

I am building a WordPress website with an Underscore theme, it is hosted on flywheel. Everytime I make changes to a page, the styling style.css file is not picked up unless I do a hard reload/ clear ...
0
votes
1answer
34 views

Wordpress Userroles button getting cached

I am having different buttons for different users in my site, i have used the below code to create those. <?php global $user_login, $current_user; get_currentuserinfo(); $user_info = ...
7
votes
2answers
8k views

Getting failure when using filemtime() with wp_enqueue_style

I am trying to change the stylesheet file version using the filemtime() function with the wp_enqueue_style with the following snippet function pro_styles() { wp_enqueue_style( 'child-style', ...
0
votes
1answer
69 views

Should i clear the plugin cache for cache busting?

I need to understand the correct way to use cache busting, because i know that i can use a query string for version which changes in every file update, but i prefer to use cache busting through ...
1
vote
0answers
16 views

Published site reverts without changes to theme

I recently added a search bar to our website by adding a plugin and adding that plugin into the appropriate place in our theme. I also added an event listener as an attribute on an element in another ...
0
votes
2answers
49 views

My homemade plugin is trying to update to someone else's plugin

Wordpress is telling me that my self-built plugin has an update available, and this link leads me to someone else's repo. After I first saw this message, I read a lot of questions on here asking ...
-1
votes
3answers
28 views

Cache of site on browser

I am making a wordpress site and it contains a media link. As when media file on server changes it don't get updated on my site. To see my new media i have to open new tab in browser, otherwise it is ...
0
votes
2answers
382 views

Adding a URL Parameter to JPEG images in posts

To avoid image caching issues, I would like to get WordPress to reference my jpeg images with a URL parameter. I know in javascript I can do this: <img id="idSigma" src="#" class="classSigma"> ...
1
vote
1answer
2k views

How do I force WP_query to fetch fresh, non-cached results?

Context: In a social sharing plugin that I work on, I'm store social share counts in hidden post meta (custom fields) so that I can use that data for various functions around the plugin. One useful ...
0
votes
1answer
702 views

Timthumb isn't displaying any images. "A TimThumb error has occured

I have a Wordpress web site which is hosted on a distributed infrastructure. I have a web server(apache) and a cache server (varnish). When I load the site directly from web server everything is OK, ...
0
votes
1answer
40 views

Force 'permanent' post cache of shortcode results

Backstory: I am generating posts from rss feeds adding additional content to the post using shortcodes. Problem is that every time the page is refreshed the shortcodes fire and load new content. ...
0
votes
2answers
26 views

How can I control if post updated

I am trying to write cache plugin for my web site. How can I control if post or page updated or added new page or post
1
vote
1answer
165 views

Transient feeds and caching error

On our production and staging servers, we're seeing the "WordPress News" feed show an error: After poking around in the WP codebase a bit, I've discovered that this is stored in the wp_options table ...
0
votes
1answer
283 views

Wordpress caching in development

I have an issue with Wordpress development that I'm sure is a relatively new occurence. I am on Mac osx sierra 10.12.3. I'm using MAMP PRO 4.1.1. I'm on Chrome 58.0.3029.110 (64 bit). If I make a ...
1
vote
1answer
601 views

Nav and logo loading each time causing menu to move JointsWP - Foundation 6

Hi I was wondering if anyone could help. I'm creating a site using JointsWP Foundation 6 theme and have created a new fixed side menu which includes the logo and social links. My problem is ...
0
votes
2answers
2k views

Combining several CSS files into one for optimization

I have an idea. And I hope it is already implemented somehow. Here is an example of CSS files in the head of a page <link rel='stylesheet' id='validate-engine-css-css' href='https://example.net/...
0
votes
1answer
124 views

Caching the_content calls

I am writing a very small cache plugin called Tiny Cache. It would cache only the_content() calls which take - I think - the longest time to generate during a page load. I am able to hook the_content ...
1
vote
0answers
46 views

Should wp_query automatic meta and term cache priming be used in an enviroment with an object caching

This is kind of followup question to Explanation of update_post_(meta/term)_cache which discusses the disabling of automatic meta and term caches by setting to false both update_post_meta_cache and ...
0
votes
1answer
1k views

Disabling WP-Admin Caching in htaccess

since ca. 4-6 weeks I have caching problems in my WP backend. Frontend of WP site is: www.speed-ville.de Examples for caching problems: – modifications don’t show up (in browser in backend) – e.g. I ...
1
vote
0answers
194 views

Wordpress Leverage browser caching Show how to fix & Eliminate render-blocking JavaScript and CSS in above-the-fold content Show how to fix

Good afternoon , as the title says I have the following problems that I tried and cannot find a solution for , I already tried the different solutions people posted here in different topics . So ...
0
votes
1answer
301 views

Is WordPress cache shared for all blogs in a multisite network?

When I do a wp_cache_set( 'some-item', $item, 'my-group' ) on any site of the multisite network, is some-item available on other blogs, or does every blog have its own "cache domain"? If cache is ...
2
votes
1answer
2k views

W3 total Cache - Site with query strings

I have a blog were most of the traffic comes with query strings for tracking purposes, which means that query strings doesn't change the content of the site. As I recently learned - W3 Total Cache &...
1
vote
1answer
297 views

Will setcookie work if there is a cache plugin installed?

A cache plugin in WP will cache PHP output, but does it include HTTP header? For example, add a piece of code as following: add_action('wp', 'my_cookie' ); function my_cookie() { setcookie('...
1
vote
1answer
62 views

Functions.php reverted to new one

First of all, sorry for not being able to phrase my question correctly. Then here is my problem - Some days ago I did some changes to my functions.php (one in wp_includes not in theme). I read that ...
0
votes
1answer
362 views

Hook directly into query execution

I am building a simple caching class and I want to use this class to cache queries. My initial thinking was to create a Query class and use this to handle all queries, meaning the Query class would ...
1
vote
1answer
145 views

Dynamic content in template

okay, so here is a quick example of code in a template, page.php, file: <?php print_r(getdate ()); ?> Website is setup with WPEngine. When logged in (into wordpress) works 100% and date/time ...
3
votes
1answer
660 views

Website not updating - no cache plugins active!

I've a problem with my WordPress website getting updated after I make changes to its code: I'm using phpStorm with auto-save, running the website on WAMP, locally. Therefore, right after I right new ...
1
vote
0answers
42 views

SuperCache for Custom Templates

I've started creating custom templates. For instance, I wanted a news template for posts that are news oriented. So, I made news.php <?php /* * Template Name: News Article * Template Post Type: ...
8
votes
3answers
6k views

How do I cache (core) API requests?

I'm am currently trialling the new (as of 2017) core API built into Wordpress. My setup is reasonably simple: +---------+ +------+ +---------+ |Wordpress|<-->|Guzzle|<-->| App ...
1
vote
0answers
266 views

Cache wp-json/posts without a plugin?

Is there a way to cache the following url on my site without using a plugin? www.domain.com/wp-json/posts?type=custom_post_type&filter%5Bposts_per_page%5D=5&filter%5Btaxonomy%5D=events_cat ...
1
vote
0answers
30 views

WordPress returns to an old version

I'm creating a WordPress site and today it has returned to an old version of himself. I don't mean a downgrade, but it has changed the slider, menu's links, widgets, etc to as it was weeks ago. How ...
0
votes
1answer
4k views

WP REST API and Access-Control-Allow-Origin

In one of my project I use a Wordpress REST Api. When I was enabled cache by WP Super Cache plugin I have an error now: XMLHttpRequest cannot load http://api.mydomain.com/wp-json/wp/v1/posts. Origin ...
1
vote
1answer
38 views

Accelerate and clean up WordPress [closed]

I almost finished my WordPress site after 2 monaths... Because there were a lot of custom code work, it took me so long. Furthermore I created over 18000 sites, deleted them and was testing. My ...
0
votes
3answers
822 views

site url is not working after migrtaion in worpress, all links are broken

I migrated a WordPress website on my sub directory and change both site_url from wp_options table.Flush the permalink as well but still links are broken. It seems that site_url() is not working. CSS, ...
1
vote
2answers
2k views

With W3 Total Cache when I publish a post it does not appear in the homepage. Only if i purge all cache [closed]

If you go to the ps4 page you will see that the last post is there My Site Is it necessary to do something for the post to appear on the homepage or should it appear by default?
1
vote
1answer
1k views

Possible to configure nginx to ignore cache for logged in users in certain roles only?

I have nginx caching setup that ignores logged in users, but I have a lot of users in subscriber roles who SHOULD be served a mostly cached site. Is there a way to only ignore caching for SOME roles (...
3
votes
3answers
1k views

Setting Last Modified HTTP Header on static Home Page

In response to the question asked here I find myself and this other user needing a solution to set a last modified header that contains the date and time of the most reicent post. Since we both in ...
1
vote
2answers
280 views

Help Pinpointing Source of Caching Issue

When viewing the home page of my site (zilredloh.com), sometimes I do not see the latest posts. A new post will have been published, but the main index page doesn't reflect this. Refreshing the ...
1
vote
0answers
225 views

Losing preview ability: W3 Total Cache + Post name permalinks

I've been seeing issues on sites when I enable W3 Total Cache (Using an aws cdn) where the ability to preview pages would be lost. I was just able to confirm this when enabling it on a new site. A ...
0
votes
1answer
653 views

How can I leverage browser cache for minified JS or minified CS files?

I am absolutely comfortable utilizing HTACCESS but I am working on speed load. I have a minified JS file. How would I go about adding this into my HTACCESS? Below I was going to add this line to ...
0
votes
1answer
114 views

custom php file inside my custom folder of plugins directory is not caching

I am using W3-Total-Cache plugin, here is my plugin configurations : I am trying to implement caching on my custom php file. I have created a folder (api) inside plugins directory. i.e /wp-content/...
1
vote
1answer
86 views

Transient loop issue

I have the following which works fine but only cache first value for first post and doesn't store data for all movie posts in database. How I can solve this problem? I have also a live perview of this ...
1
vote
1answer
933 views

Does get_terms() use any sort of caching on its query?

In the docblock for get_terms(), it says the following on caching: * The {@see 'get_terms'} filter will be called when the cache has the term and will * pass the found term along with the array of $...
0
votes
0answers
488 views

Css style removed but still showing via CDN even after clearing browser cache and purging all caches for site

I have an issue where the mobile menu (Must change browser size to mobile width to see) is showing one of its lines as "display:none" via the stylesheet. So the hamburger icon is wrong. See screenshot....
-1
votes
1answer
3k views

Levels of caching and impact on the WordPress web site

Recently I have tried to answer this question and I noted how important is to understand the caching when solving Wordpress problems. Namely, I just wanted to summarize the possible levels of caching ...
0
votes
1answer
2k views

No Query String vs Ignore Query String in WordPress

I use Cloudflare and there is an option of choosing Cache level. The following are the level of Caches available [check image]- I have selected Standard. Which one should I be using for better page ...
0
votes
1answer
1k views

wp_transients | wp_object_cache VS SESSIONS & Cookies?

My plugin requires me to save query data for some time. The data isn't big as such; just a couple of search parameters entered by the user so that I can use them across pagination. I've figured out ...
0
votes
1answer
149 views

flush_widget_cache is deprecated. Which method should i use instead?

The reviewer of my theme told me that flush_widget_cache() which I have used in one of my widgets is deprecated since version 4.4. I have searched for this method on codex but there is only a ...

1 2 3
4
5
12