Conversation
supportHi, The home page url is defaulting to the ‘last blog post” Canonical link, instead of the home page URL. The page it references, uses the correct Canonical. However, the home page is wrong and needs fixing. I’ve tried to fix this but with no success. Help appreciated, thanks! Cheers The page I need help with: [ log in to see the link]
I’m looking into this. Thanks!
It will be fixed in the next release.
OK.. What would the time frame be on the “next” release?
End of next week. Are you comfortable with editing code? I have quick fix that may work for you.
Yes I can edit code, as long as I’m given the right instruction etc 🙂
Line 61/62 of app/Admin/Header.php move $sseo_canonical_url = null; To line 42 above: if (is_front_page() && is_home()) { /* Default Homepage */ You want that first if statement to basically look like this: $sseo_canonical_url = null; if (is_front_page() && is_home()) { /* Default Homepage */ $description = get_option('sseo_default_meta_description'); $keywords = get_option('sseo_default_meta_keywords'); $sseo_canonical_url = get_home_url(); /* set canonical url to homepage */ } elseif (is_home()) { /* Blog Page */ Let me know if that works. It should, its what I have set for the new release, along with other things.
Thank you David, I will add this now, and return in 30min or so to provide an update.
It happens to the best of us… I’m checking that you meant: app/Admin/Meta/Header.php not: app/Admin/ (there’s not Header.php there)
Correct.
$sseo_canonical_url = null; if (is_front_page() && is_home()) { /* Default Homepage / $description = get_option('sseo_default_meta_description'); $keywords = get_option('sseo_default_meta_keywords'); } elseif (is_home()) { / Blog Page */ Added as instructed… Have doubled checked and $sseo code line removed fom original position, and inserted as above. Hasn’t made any change. However, I’ve got some ISP cache issue that’s driving me nuts, over last few days. F5 refresh, clear DNS cache, change dsn servers, nothing fixes the issue. I”ll give it an hour or so and report back then. Cheers
Please excuse the typos. It’s just gone 4am Friday.
If your using Chrome you can open developer tools, then right click the refresh button and choose “empty cache and hard reload”, doing it in an incognito window might help as well. Resetting your router to obtain a new DNS may help also.
I have a dedi IP from my ISP – great for lots of reasons, all except, it seems, now. The other possibility… Have a managed VPS, and 5 or so days ago they updated to the latest Litespeed version. Previous to this, no cache issues. I’ve submitted a support ticket. Maybe something server sided is causing this.
According to support, they’ve gone ahead and updated litespeed web server to: (6.3.1 (build 5)). In addition, have flushed any caches and whatnot. So that should be all good, now. Decided to disconnect from ISP, and reconnected to my mobile’s Hotspot. Well, that didn’t change anything, the Home page Canonical is still pointing to the last blog post. <link rel="canonical" href=" https://blog.doch.fyi/online-gambling-industry/igaming-affiliates-fair-treatment/ " /><!-- / Simple SEO plugin. -->
Okay, still looking into it.
Is your homepage set as the blog?
Edit… Sorry just woke up, the site is set to blog. This reply was modified 1 year, 6 months ago by ozguy .
Thanks! Life has been busy lately so I’ve not been able to trouble shoot this, but it is on the list. Hopefully I will have it resolved in the next commit. I do not have a date for for that release.
I’ve ended up moving the blog to new domain, instead of using a sub-domain. I’m unable to edit the URL hidden link, and instead of commencing a new thread, I’ll pm/email you the details. Cheers This reply was modified 1 year, 5 months ago by ozguy . This reply was modified 1 year, 5 months ago by ozguy .
I completely understand, reason I created SimpleSEO. I hope to commit more changes after xmas, so sometime next week.
I just tried to send you a DM on slack and your slack ID is returning an error. https://doch.blog/ is missing the canonical, all other pages/blogs are displaying the correct canonical, but as stated previously, the canonical for the blog’s home page, is MIA. My new blog posts usually get indexed on G within literally a couple of hours. So it’s not a huge issue. But I would like the home page to display a canonical of the home page url. You’ll have to use the browser search function if viewing the code, I use Litespeed server, along with litespeed plugin, all the code etc, is optimized. This reply was modified 1 year, 5 months ago by ozguy . This reply was modified 1 year, 5 months ago by ozguy .
Forgot to mention… If your accessing the url, cloud servers and VPN’s will likely get a 403. Way too many nefarious bots, scrapers, script kiddies and what not, hit the site so they’re blocked. Access via ISP is fine.
I just posted an update for the canonical url issue(s).
Thank you David!
Let me know if there are any issues.
I ran some checks and all is working as it should, thanks 🙂
I’m looking into this. Thanks!
It will be fixed in the next release.
OK.. What would the time frame be on the “next” release?
End of next week. Are you comfortable with editing code? I have quick fix that may work for you.
Yes I can edit code, as long as I’m given the right instruction etc 🙂
Line 61/62 of app/Admin/Header.php move $sseo_canonical_url = null; To line 42 above: if (is_front_page() && is_home()) { /* Default Homepage */ You want that first if statement to basically look like this: $sseo_canonical_url = null; if (is_front_page() && is_home()) { /* Default Homepage */ $description = get_option('sseo_default_meta_description'); $keywords = get_option('sseo_default_meta_keywords'); $sseo_canonical_url = get_home_url(); /* set canonical url to homepage */ } elseif (is_home()) { /* Blog Page */ Let me know if that works. It should, its what I have set for the new release, along with other things.
Thank you David, I will add this now, and return in 30min or so to provide an update.
It happens to the best of us… I’m checking that you meant: app/Admin/Meta/Header.php not: app/Admin/ (there’s not Header.php there)
Correct.
$sseo_canonical_url = null; if (is_front_page() && is_home()) { /* Default Homepage / $description = get_option('sseo_default_meta_description'); $keywords = get_option('sseo_default_meta_keywords'); } elseif (is_home()) { / Blog Page */ Added as instructed… Have doubled checked and $sseo code line removed fom original position, and inserted as above. Hasn’t made any change. However, I’ve got some ISP cache issue that’s driving me nuts, over last few days. F5 refresh, clear DNS cache, change dsn servers, nothing fixes the issue. I”ll give it an hour or so and report back then. Cheers
Please excuse the typos. It’s just gone 4am Friday.
If your using Chrome you can open developer tools, then right click the refresh button and choose “empty cache and hard reload”, doing it in an incognito window might help as well. Resetting your router to obtain a new DNS may help also.
I have a dedi IP from my ISP – great for lots of reasons, all except, it seems, now. The other possibility… Have a managed VPS, and 5 or so days ago they updated to the latest Litespeed version. Previous to this, no cache issues. I’ve submitted a support ticket. Maybe something server sided is causing this.
According to support, they’ve gone ahead and updated litespeed web server to: (6.3.1 (build 5)). In addition, have flushed any caches and whatnot. So that should be all good, now. Decided to disconnect from ISP, and reconnected to my mobile’s Hotspot. Well, that didn’t change anything, the Home page Canonical is still pointing to the last blog post. <link rel="canonical" href=" https://blog.doch.fyi/online-gambling-industry/igaming-affiliates-fair-treatment/ " /><!-- / Simple SEO plugin. -->
Okay, still looking into it.
Is your homepage set as the blog?
Edit… Sorry just woke up, the site is set to blog. This reply was modified 1 year, 6 months ago by ozguy .
Thanks! Life has been busy lately so I’ve not been able to trouble shoot this, but it is on the list. Hopefully I will have it resolved in the next commit. I do not have a date for for that release.
I’ve ended up moving the blog to new domain, instead of using a sub-domain. I’m unable to edit the URL hidden link, and instead of commencing a new thread, I’ll pm/email you the details. Cheers This reply was modified 1 year, 5 months ago by ozguy . This reply was modified 1 year, 5 months ago by ozguy .
I completely understand, reason I created SimpleSEO. I hope to commit more changes after xmas, so sometime next week.
I just tried to send you a DM on slack and your slack ID is returning an error. https://doch.blog/ is missing the canonical, all other pages/blogs are displaying the correct canonical, but as stated previously, the canonical for the blog’s home page, is MIA. My new blog posts usually get indexed on G within literally a couple of hours. So it’s not a huge issue. But I would like the home page to display a canonical of the home page url. You’ll have to use the browser search function if viewing the code, I use Litespeed server, along with litespeed plugin, all the code etc, is optimized. This reply was modified 1 year, 5 months ago by ozguy . This reply was modified 1 year, 5 months ago by ozguy .
Forgot to mention… If your accessing the url, cloud servers and VPN’s will likely get a 403. Way too many nefarious bots, scrapers, script kiddies and what not, hit the site so they’re blocked. Access via ISP is fine.
I just posted an update for the canonical url issue(s).
Thank you David!
Let me know if there are any issues.
I ran some checks and all is working as it should, thanks 🙂