Infinite scrolling isn't working on my blog with Casper

  • What’s your URL? https://skerritt.blog/
  • What version of Ghost are you using? Ghost-CLI version: 1.9.8, ghost version 2.9.1
  • What configuration? Using Casper, on DigitalOcean one click install.
  • What browser? Firefox, but this issue also affects Chrome
  • What errors or information do you see in the console? None
  • What steps could someone else take to reproduce the issue you’re having?
    I’m not sure to be honest :frowning_face:

I want infinite scrolling like here:
https://john.onolan.org/
I have more than 25 posts, and looking at my posts in the Ghost writer the last post on my blog isn’t the last post I’ve published.
I’ve noticed that other blogs have infinite scroll (https://spreadprivacy.com) too. I’ve looked around in the settings and I couldn’t find anything that useful. I’ve deleted all code injections and it didn’t help.

I don’t have pages either. It just cuts off completely :(

I found infinite scroll on GitHub here, under default.hbs and I checked my code to see if it was there as well - it is.

Any help would be appreciated! Thank you so much :smile:

All of your URLs link using http (as opposed to https)

Assuming you are running a self hosted instance of ghost, the fix should be running

ghost config set url https://skerritt.blog

in your installation directory :slight_smile:

1 Like

Hey! Many thanks for your reply. When I set the url to HTTPS using this command I get an “this page isn’t redirecting properly” error in my browser in private / incognito mode. I’ve purged my cloudflare cache, SSL is set to not redirect HTTP to HTTPS. Even thedigital ocean droplet IP address doesn’t work.

I can still connect to my server via SSH. Any suggestions? Again, thank you so much for your help!!

Edit: on Chrome I’m getting “skerritt.blog redirected you too many times” error, I’ve cleared my cookies and still getting this :smile:

I tried what was detailed at the bottom here

It didn’t work for me. Setting Cloudflare to full (strict) and rerunning:

ghost setup nginx

gives me an “ssl protocols do not match” error on Firefox.

I also tried

I don’t have this issue

So far, I’ve:

  • deleted the nginx files listed at the bottom here
  • ran the command ghost config set url https://skerritt.blog
  • set cloudflare to full (strict)
  • turned on cloudflare’s development mode
  • turned off universal ssl as suggested here
  • ghost restart

This has given me “web server down”, although I don’t think it’s down as I’m connected to it via SSH. Also, I’ve restarted the server and this is still happening. I’m very new to this sort of thing, so any and all help would be appreciated :grin:

edit: When switching Cloudflare SSL to Flexible and enabling universal SSL, I get the same redirect error previously

I just created an entirely new droplet, had infintie scrolling on the IP address. Set URL to https://skerritt.blog using ghost config set url https://skerritt.blog, “page isn’t redirecting properly” so I follow this from the github issue:

" Newcomers, using the droplet image on digital ocean, check cloudflare configuration before messing with the nginx conf.

The correct configuration for cloudflare is to select Full (strict) in SSL settings and Disable Universal SSL (at the bottom of the page)

Once I disabled universal SSL and set my configuration to Full (strict) ghost was able to redirect the site to https:// every time without fault

If you need to reset your nginx configuration to the default, delete your domains configuration in /etc/nginx/sites-available and /etc/nginx/sites-enabled and rerun ghost setup nginx :+1:"

Exact same issue, cloudflare cannot connect to host :frowning_face:

Edit: I reran the entire setup again, but this time putting my website into the URL setup instead of the Droplet’s IP address. I have HTTPS, I have a working blog - but no infinite scroll. I’ve edited my URL to be HTTPS again, but it still breaks it :frowning_face:

The reason you lose infinite scrolling is because your browser is blocking connections from a secure origin (https://skerritt.blog) to an insecure origin (http://skerritt.blog). When you use the droplet IP, you’re on an insecure origin so there’s nothing to worry about

You can’t have cloudflare in flexible SSL mode because your droplet forces SSL - cloudflare article

Since you’re having trouble narrowing down the root cause of the issue, I suggest you get your site working without cloudflare as a MITM (in your dns settings make sure the cloud is grey and not orange), and then enable it and debug issues with cloudflare

One thing I forgot to mention is you need to restart ghost after updating the configuration - this can be done via ghost restart

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.