• Hello, I am using the plugin for the first time. I did the installation on my website without any problems, but I have a lot of question marks in my mind.

    – I use cloudways as web hosting.
    – I disabled Varnish cache as you suggest in the FAQ.
    – I’m not using any other caching plugin.
    – I’m using redis as a object cache.
    – My php version is 7.4 and im using inno db engine with mariadb 10.4
    – Execution limit is set to 60 sec, max file upload size is 100mb, max memory limit is 512mb (but i’m using 256 on my website.)
    -MAX INPUT VARIABLES 2500,MAX INPUT TIME 60 sec, APC MEMORY 32MB, OPCACHE MEMORY 64MB

    These are the plugins that i’m using on my website:`

    https://i.ibb.co/jRkSmQy/pluginler1.png
    https://i.ibb.co/BGKFKbt/pluginler2.png

    Akismet Anti-Spam
    Async JavaScript
    Autoptimize
    Bot Protection (Cloudways)
    Classic Editor
    Code Snippets
    GP Premium (Generate Press Premium)
    Perfmatters
    Rank Math SEO
    Rank Math SEO PRO
    Recent Posts Widget With Thumbnails
    Redis Object Cache
    WP Cloudflare Super Page Cache

    These are the WP Cloudflare Super Page Cache settings:

    Automatically purge the cache when Autoptimize flushs its cache —> yes
    Add browser caching rules for static assets —-> yes
    Automatically purge the OPcache when Cloudflare cache is purged —-> yes
    Automatically purge the object cache when Cloudflare cache is purged —> yes

    Rest of them default.

    My questions:

    1) Are my settings correct?
    2) I see this warning at every page test tool: Serve static assets with an efficient cache policy

    These are the files that shown in the warning:
    https://i.ibb.co/GxG5kM3/serve-efficient-cache-policy.jpg

    Are these warnings normal even when browser cache enabled?

    3) Can i add a page rule for my wp-admin on cloudflare?

    I want to protect wp-admin page and for this I want to add a page rule for it. Like this:

    Url: website.com/wp-admin*
    Security level: High

    Thats it. A rule like this can break plugin functionality?

    4) Is this plugin compatitible with Rank Math Seo?

    Analytics and seo analytics part do not update themselves. (I cleared the cache many times.)

    Keyword rank tracking is not working. I’m trying to add keywords at DASHBOARD / ANALYTICS / Rank Tracker / Keyword Manager but whenever I try to add a keyword nothing happens at that page. Simply i’m writing the keyword and clicking “add” button and nothing happens. (I tried cleaning everything from Rank Math’s status&tools page.)

    When I temporarily deactivated the page rule that the plugin added in the Cloudflare panel, I could see the keywords in the rank tracker once, but when I activated it again and deactivated it again, I could not access the keywords again.

    That’s all for now. I will be waiting your answers. Have a nice day.

Viewing 15 replies - 1 through 15 (of 16 total)
  • Thread Starter Fronar

    (@fronarr)

    I forgot to write. The plugin seems to be working as it should. I see the phrase cf cache status: HIT in the network section on the front pages, and the phrase BYPASS on the admin panel.

    While navigating in the admin panel, I see the expression “?swcfpc=1” in the url part of some pages, and I do not see it in others. Is this normal? Should I see “?swcfpc=1” in the entire admin panel?

    Plugin Contributor iSaumya

    (@isaumya)

    First of all you don’t need to disable varnish in your cloudways account. Inside the plugin settings you can provide the varnish cache details to autopurge that.

    2) I see this warning at every page test tool: Serve static assets with an efficient cache policy

    Moreover if your cloudways server is a nginx based server and not apache/lightspeed based, then you need to go inside /wp-contnetnt/wp-cloudflare-super-page-cache/<domain-name>/ and you can either include the nginx.conf file generated by the plugin to your main nginx config and restart your nginx or you can copy paste the nginx configs in that file and put that on your main nginx.config.

    1) Are my settings correct?

    – yes looks like that

    3) Can i add a page rule for my wp-admin on cloudflare?

    – Yes you can add a rule for security stuffs but do not overwrite anything related to any caching.

    4) Is this plugin compatitible with Rank Math Seo?

    – Fully. This plugin has nothing to do with Rankmath. I use Rankmath on all of my client sites while using this plugin.

    Analytics and seo analytics part do not update themselves. (I cleared the cache many times.)

    Keyword rank tracking is not working. I’m trying to add keywords at DASHBOARD / ANALYTICS / Rank Tracker / Keyword Manager but whenever I try to add a keyword nothing happens at that page. Simply i’m writing the keyword and clicking “add” button and nothing happens. (I tried cleaning everything from Rank Math’s status&tools page.)

    – What you are saying is not possible as all those operations are happening inside the wp-admin while you are logged-in. And when you are loggedin your cache is always bypassed and served from origin. Unless you have tinkered with the page rule added by the plugin in cloudflare anyways, this should not happen.

    If you already have 3 page rules in your CF account, remove them and then disable enable cache inside the plugin sett8ings so that it can generate the page rule in Cloudflare as it is needed.

    While navigating in the admin panel, I see the expression “?swcfpc=1” in the url part of some pages, and I do not see it in others. Is this normal? Should I see “?swcfpc=1” in the entire admin panel?

    – ALready clearly explained in the FAQ sections (both in plugin description and the FAQ tab in the plugin settings). Do read the plugin description and the FAQ tab inside the plugin settings:

    Screenshots:

    View post on imgur.com

    View post on imgur.com

    Based on the information in the FAQ, I turned off the varnish cache. I activated it again with the 8080 port. It works seamlessly.

    “Can I use this plugin together with Varnish Cache?”
    “Yes but you don’t need it. If you want to use a standard page cache behind Cloudflare, enable the fallback cache option of this plugin.

    In order to avoid conflicts, it is strongly recommended to use only this plugin as page caching system.”

    —————————————————————————
    I found the file that you mentioned.

    /wp-contnetnt/wp-cloudflare-super-page-cache/<domain-name>/
    nginx.conf

    Plugin automatically added all the rules that needed to be added. I checked them all. Here’s whats written in it if you want to check:

    location ~* \.(xml|xsl)$ { add_header Cache-Control "no-cache, no-store, must-revalidate, max-age=0"; expires -1; }
    location /robots.txt { add_header Cache-Control "no-cache, no-store, must-revalidate, max-age=0"; expires -1; }
    location ~* \.(css|js|pdf)$ { add_header Cache-Control "public, must-revalidate, proxy-revalidate, immutable, max-age=2592000, stale-while-revalidate=86400, stale-if-error=604800"; expires 30d; }
    location ~* \.(jpg|jpeg|png|gif|ico|eot|swf|svg|webp|avif|ttf|otf|woff|woff2|ogg|mp4|mpeg|avi|mkv|webm|mp3)$ { add_header Cache-Control "public, must-revalidate, proxy-revalidate, immutable, max-age=31536000, stale-while-revalidate=86400, stale-if-error=604800"; expires 365d; }
    location /wp-cron.php { add_header Cache-Control "no-cache, no-store, must-revalidate, max-age=0"; expires -1; }
    location = /wp-content/wp-cloudflare-super-page-cache/websitename.com/debug.log { access_log off; deny all; }

    I tried restarting nginx alone, then the whole server. Still i see the error on page test tools i don’t know why.

    – ALready clearly explained in the FAQ sections (both in plugin description and the FAQ tab in the plugin settings). Do read the plugin description and the FAQ tab inside the plugin settings:

    I think you don’t fully understand this part. I am aware that the parameter I see is the way the plugin works, but what I really meant was that I did not see this parameter in every url while navigating the admin panel. Is it normal that I don’t see it in every url or should it be in all?

    Thank you for your help, I will be looking forward to your next reply.

    Plugin Contributor iSaumya

    (@isaumya)

    Based on the information in the FAQ, I turned off the varnish cache. I activated it again with the 8080 port. It works seamlessly.

    – See, once this plugin is active then only the uncached requests will served via your server. When a page is cached in CF cache then it will be served from CF CDN and your server won’t have to do a thing. So, if you have fallback cache enable, you can turn the varnish on or off, totally up to you. Best to test with both turned on and off and see what works best in your case and keep that.

    I tried restarting nginx alone, then the whole server. Still i see the error on page test tools i don’t know why.

    – You haven’t shared your website URL so I can’t check the cache-control header they are getting. If you want you can check if the nginx rule is taking effect or not.

    but what I really meant was that I did not see this parameter in every url while navigating the admin panel. Is it normal that I don’t see it in every url or should it be in all?

    – Whn you are inside WP Admin you won’t see the cache buster query string. You will only see it when you are logged-in and accessing the front end pages.

    My website adress is: mydesignbag.com

    if you can check it for me, I would be grateful. Thank you for all your help.

    Plugin Contributor iSaumya

    (@isaumya)

    I don’t see the static files has the cache control which is present in the nginx.conf generated by the plugin. See the screenshots:

    View post on imgur.com

    View post on imgur.com

    View post on imgur.com

    If you are using nginx server, make sure that the nginx rules added by the plugin has been added properly in your main nginx.conf file either by importing this file to the main config file or copy pasting the content of this config file to the main config file and then restarting the nginx.

    Cloudways gives the answer to this question as “both apache and nginx are used together on our servers”. If it’s Apache, I don’t need to do anything, for nginx I need to add code (already added) but I don’t understand why it doesn’t work. I’m super confused at this point.

    Here’s the working services on the server: https://i.ibb.co/60jw43p/Screenshot-5.png

    these are default services by the way, i just installed redis on this.

    Plugin Contributor iSaumya

    (@isaumya)

    Yes if your main server is running on apache then it should add the code automatically in the .htaccess file.
    Can you check your htaccess file and share the code you have in there?

    # BEGIN rlrssslReallySimpleSSL rsssl_version[4.0.15]
    <IfModule mod_rewrite.c>
    	RewriteEngine on
    	RewriteCond %{HTTP:CF-Visitor} '"scheme":"http"'
    	RewriteRule ^(.*)$ https://%{HTTP_HOST}/$1 [R=301,L]
    </IfModule>
    # END rlrssslReallySimpleSSL
    # BEGIN WordPress
    # The directives (lines) between "BEGIN WordPress" and "END WordPress" are
    # dynamically generated, and should only be modified via WordPress filters.
    # Any changes to the directives between these markers will be overwritten.
    <IfModule mod_rewrite.c>
    	RewriteEngine On
    	RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
    	RewriteBase /
    	RewriteRule ^index\.php$ - [L]
    	RewriteCond %{REQUEST_FILENAME} !-f
    	RewriteCond %{REQUEST_FILENAME} !-d
    	RewriteRule . /index.php [L]
    </IfModule>
    
    # END WordPress
    
    # BEGIN WP Cloudflare Super Page Cache
    # The directives (lines) between "BEGIN WP Cloudflare Super Page Cache" and "END WP Cloudflare Super Page Cache" are
    # dynamically generated, and should only be modified via WordPress filters.
    # Any changes to the directives between these markers will be overwritten.
    <IfModule mod_expires.c>
    ExpiresActive on
    ExpiresByType application/xml "access plus 0 seconds"
    ExpiresByType text/xsl "access plus 0 seconds"
    </IfModule>
    <FilesMatch "\.(xml|xsl)$">
    <IfModule mod_headers.c>
    Header set Cache-Control "no-cache, no-store, must-revalidate, max-age=0"
    </IfModule>
    </FilesMatch>
    <FilesMatch "robots\.txt">
    <IfModule mod_headers.c>
    Header set Cache-Control "no-cache, no-store, must-revalidate, max-age=0"
    </IfModule>
    </FilesMatch>
    <FilesMatch "\.(css|js|pdf)$">
    <IfModule mod_headers.c>
    Header set Cache-Control "public, must-revalidate, proxy-revalidate, immutable, max-age=2592000, stale-while-revalidate=86400, stale-if-error=604800"
    </IfModule>
    </FilesMatch>
    <FilesMatch "\.(jpg|jpeg|png|gif|ico|eot|swf|svg|webp|avif|ttf|otf|woff|woff2|ogg|mp4|mpeg|avi|mkv|webm|mp3)$">
    <IfModule mod_headers.c>
    Header set Cache-Control "public, must-revalidate, proxy-revalidate, immutable, max-age=31536000, stale-while-revalidate=86400, stale-if-error=604800"
    </IfModule>
    </FilesMatch>
    <IfModule mod_rewrite.c>
    RewriteCond %{REQUEST_URI} ^(.*)?/wp-content/wp-cloudflare-super-page-cache/mydesignbag.com/debug.log(.*)$
    RewriteRule ^(.*)$ - [F]
    </IfModule>
    <FilesMatch "wp-cron.php">
    <IfModule mod_headers.c>
    Header set Cache-Control "no-cache, no-store, must-revalidate, max-age=0"
    </IfModule>
    </FilesMatch>
    # END WP Cloudflare Super Page Cache
    
    # MalCare WAF
    <Files ".user.ini">
    	<IfModule mod_authz_core.c>
    		Require all denied
    	</IfModule>
    	<IfModule !mod_authz_core.c>
    		Order deny,allow
    		Deny from all
    	</IfModule>
    </Files>
    
    # END MalCare WAF
    # BEGIN Robin Image Optimizer Webp
    # The directives (lines) between "BEGIN Robin Image Optimizer Webp" and "END Robin Image Optimizer Webp" are
    # dynamically generated, and should only be modified via WordPress filters.
    # Any changes to the directives between these markers will be overwritten.
    
    # END Robin Image Optimizer Webp

    Thats how my htaccess is. It seems that the rules that the plugin should add have been added.

    Plugin Contributor iSaumya

    (@isaumya)

    First of all you don’t need really simply SSL one.

    secondly, I see the htaccess rules for adding proper cache control for static files are there but no idea why it is not taking an effect. For that explanation, you might need to contact your host and ask why they are not taking effect.

    I found what caused the problem. I accidentally changed my SSL setting to flexible mode on Cloudflare. (I needed to use flexible for another site, I didn’t pay much attention to the site names when I was sleepy at night.)

    I think the problem is completely fixed now. Can you check again?
    At the same time, the problem of the rankmath plugin not updating itself seems to have been fixed.

    Right now SSL setting is set to full(strict) and i deleted the part written by really simple ssl plugin at htaccess.

    Plugin Contributor iSaumya

    (@isaumya)

    I am still not seeing the cache control mentioned in the htaccess. You can check it yourself too. Just check the chrome dev tools network tab and check the cache control header of a css or js or image file and then tally that with what mentioned in the htaccess file.

    Thread Starter Fronar

    (@fronarr)

    Hello again, Saumya

    In addition to the plugin, I installed wp-rocket to solve the browser cache issue. I guess there is no problem now. Can you check it for me and confirm everything is ok?

    I will be waiting your answer, thank you.

Viewing 15 replies - 1 through 15 (of 16 total)
  • The topic ‘Lots Of Question & Problem With Rankmath’ is closed to new replies.