Oh no! Where's the JavaScript?
Your Web browser does not have JavaScript enabled or does not support JavaScript. Please enable JavaScript on your Web browser to properly view this Web site, or upgrade to a Web browser that does support JavaScript.
Sign In
Not a member yet? Click here to register.
Forgot Password?
Navigation

Facebook Sharing Debugger cannot see the articles

Last updated on 3 years ago
Posted 3 years ago
Hello
Articles on my website are not displaying correctly when sharing to Facebook. Facebook Sharing Debugger indicates that it gets redirected to the home page every time.

Quote

Input URL https://compforum.pl/infusions/news/news.php?readmore=1064
301 HTTP Redirect https://compforum.pl/news/1064/artykul-testowy
og:url Meta Tag https://compforum.pl/


What did I do wrong?
Edited by AdrianCelej on 17-06-2022 20:55, 3 years ago
AdrianCelej attached the following image:
Image not found
F
FalkSuper Admin
Posted 3 years ago
Do you get same results with https://compforum.pl/news/1064/artykul-testowy as input URL?
Posted 3 years ago
Yes
C
ChanSuper Admin
Posted 3 years ago
Alright, I have set up a new test server on the latest GitHub version. I took a sample page and compared to yours.

My finding is that your site has a weird OG going on, which I do not know whether is customized by your end? Because the one supplied by our stock version has a different output and is working fine. The problem is that your og Type is indicating a website, while the actual stock one will say it is an article, and your url is root url while the one supplied by stock will have the non-SEF url formatted url values.

Please see attachment of both HTML source comparison for this.

www.php-fusion.co.uk/infusions/forum/attachments/og_capture.png


Please view source, (or use Facebook Debugger) on this - https://next.php-fusion.co.uk/news/1/test-news-subject
Edited by Chan on 29-08-2022 03:05, 3 years ago
Chan attached the following image:
Image not found
Posted 3 years ago
The test page is indexing correctly
I remembered that in previous work I had to disable a single line in the htaccess file because it was showing an internal server error. Here is this file:
# Disable directory listing
Options -Indexes

# Force utf-8 charset
AddDefaultCharset UTF-8
AddCharset UTF-8 .html .css .js .svg .woff .woff2

# Security
ServerSignature Off

# Protect .htaccess file
<Files .htaccess>
 Require all denied
</Files>

# Protect config.php
<Files config.php>
 Require all denied
</Files>

# Protect fusion_error_log.log
<Files fusion_error_log.log>
 Require all denied
</Files>

# Protect .cache files
<Files *.cache>
 Order allow,deny
 deny from all
</Files>

<ifModule mod_headers.c>
 Header set X-Content-Type-Options "nosniff"
</ifModule>

ErrorDocument 401 /error.php?code=401
ErrorDocument 403 /error.php?code=403
ErrorDocument 404 /error.php?code=404
# Options +SymLinksIfOwnerMatch <------- I turned this line off
<ifModule mod_rewrite.c>
 # Let PHP know mod_rewrite is enabled
 <ifModule mod_env.c>
 SetEnv MOD_REWRITE On
 </ifModule>
 RewriteEngine On
 RewriteBase /
 # Fix Apache internal dummy connections from breaking [(site_url)] cache
 RewriteCond %{HTTP_USER_AGENT} ^.*internal dummy connection.*$ [NC]
 RewriteRule .* - [F,L]
 # Exclude /administration and /themes directories and images from rewrite rules
 RewriteRule ^(administration|themes)/*$ - [L]
 RewriteCond %{REQUEST_FILENAME} !-f
 RewriteCond %{REQUEST_FILENAME} !-d
 RewriteCond %{REQUEST_FILENAME} !-l
 RewriteCond %{REQUEST_URI} !^/(administration|config|index.php)
 RewriteRule ^(.*?)$ index.php [L]
</ifModule>

Could this be a problem?
Edited by AdrianCelej on 29-08-2022 23:44, 3 years ago
You can view all discussion threads in this forum.
You cannot start a new discussion thread in this forum.
You cannot reply in this discussion thread.
You cannot start on a poll in this forum.
You cannot upload attachments in this forum.
You can download attachments in this forum.
You cannot up or down-vote on the post in this discussion thread.
You cannot set up a bounty in this discussion thread.
Moderator: Support Team
Users who participated in discussion: Falk, Chan, AdrianCelej