I have a page that redirects to another page I'm trying to test my url on: https://developers.facebook.com/tools/debug
I get this error:
Errors That Must Be Fixed:
Circular Redirect: Circular redirect path detected (see Redirect Path section for details).
Warnings That Should Be Fixed:
The og:url property should be explicitly provided, even if a value can be inferred from other
tags.
- How can I fix this problem?
- How to detect Facebook and, if it is Facebook, don't redirect?
I just resolved this by adding a "/" to the end of the Facebook url meta tag. So, changed
to
and that did the trick!
I had same error: In my case the problem was www. in canonical url against fetched. Matched and problem disappeared.
Maybe adding the title after the page load helps
http://digdog.tumblr.com/post/1134982957/integrate-tumblr-template-with-facebook-open-graph
It should be clear from the details given below in the redirect path section of the debugger output: In most cases this happens because you've specified an
og:url
tag pointing to (for example) 'mysite.com/articles' and this redirects to 'mysite.com/articles/' - the crawler then goes to 'mysite.com/articles' and gets the og:url tag pointing it back to 'mysite.com/articles'Check the
Canonical URL
in https://developers.facebook.com/tools/debug as to where it's getting redirected. If there is a 302 redirect, then either you have to remove that redirect or give the redirected path asog:URL
meta tag value.If
http
is getting redirect tohttps
. Then give https://your-sitename.com as the new value of og:URL.Please note this will reset your all old comments.
I've found a workaround and although it's on a
LAMP
stack something similar must be possible with.NET
.Checking the
Apache server
log while using theFacebook Linter
I got:I now check if the User-Agent contains:
facebookexternalhit
if so I display the original page, if not I redirect to the new url.You can use the following
RewriteCond
inApache
to make sure that your rewrite rule will only run if the User-Agent IS NOT (pay attention to the exclamation mark)facebookexternalhit
.This solution is risky, if Facebook decides to change their User-Agent header you will be royally ... but for now it seems to do the trick.