• Home
  • Get help
  • Ask a question
Last post 21 min ago
Posts last week 89
Average response time last week 30 min
All time posts 67706
All time tickets 10463
All time avg. posts per day 21

Helpdesk is open from Monday through Friday CET

Please create an (free) account to post any question in the support area.
Please check the development versions area. Look at the changelog, maybe your specific problem has been resolved already!
All tickets are private and they cannot be viewed by anyone. We have made public only a few tickets that we found helpful, after removing private information from them.

#2989 – Twitter card don't show the correct image

Posted in ‘sh404SEF’
This is a public ticket. Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.
Tuesday, 22 November 2016 01:40 UTC
galamarco
 Hi,
on my site sh404sef component pint the 1st image url but not the 1st image url of the article.

For exemple.
Article URL: http://www.xxxx.it/20161103523/la-mappa-del-rischio-sismico-in-italia.html
Image in this article: http://xxxx.it/images/notizie/2016-11/mappa_del_rischio_sismico_in_italia.png

The component use this image ur: http://www.xxxx.it/images/notizie/2016-11/terremoto_roma_evacuato_palazzo_scala_e.png

How can I set the corretct image?

Tnx
Tuesday, 22 November 2016 07:43 UTC
wb_weeblr
Hi

sh404SEF offers you multiple options there:

- select if you want 1st image in the page content, or the largest image in the page.
- if your article has a "Full image" or an "Intro" image, we will use that instead of the auto-detection
- you can manually select the image in the URL manager: you find the URL of the page, go to "Social networking" tab and enter the image you want to use.

Rgds
 
Tuesday, 22 November 2016 09:21 UTC
galamarco
The setting in "Social networking" tab are correct ("use largest image in content") but the code is wrong. The component use only one photo in all website article...

Article url: http://www.xxxx.it/20161103523/la-mappa-del-rischio-sismico-in-italia.html
Image article url: http://xxxx.it/images/notizie/2016-11/mappa_del_rischio_sismico_in_italia.png

code:
<!-- sh404SEF OGP tags -->
<meta property="og:locale" content="it_IT" />
<meta property="og:title" content="La mappa del rischio sismico in Italia Scossa di Terremoto" />
<meta property="og:description" content="La mappa del rischio sismico in Italia è navigabile per scoprire, comune per comune la perciolosità e il rischio di terremoti nelle regioni Italiane" />
<meta property="og:type" content="article" />
<meta property="og:url" content="http://www.xxxx.it/20161103523/la-mappa-del-rischio-sismico-in-italia.html" />
<meta property="og:image" content="http://www.xxxx.it/images/notizie/2016-11/terremoto_roma_evacuato_palazzo_scala_e.png" />
<meta property="og:image:width" content="500" />
<meta property="og:image:height" content="281" />
<meta property="og:site_name" content="xxxx.it" />
<meta property="fb:app_id" content="1370148193026006" />
<!-- sh404SEF OGP tags - end -->
<!-- sh404SEF Twitter cards -->
<meta name="twitter:card" content="summary" />
<meta name="twitter:site" content="@xxxx" />
<meta name="twitter:creator" content="@xxxx" />
<meta name="twitter:title" content="La mappa del rischio sismico in Italia Scossa di Terremoto" />
<meta name="twitter:description" content="La mappa del rischio sismico in Italia è navigabile per scoprire, comune per comune la perciolosità e il rischio di terremoti nelle regioni Italiane" />
<meta name="twitter:url" content="http://www.xxxx.it/20161103523/la-mappa-del-rischio-sismico-in-italia.html" />
<meta name="twitter:image" content="http://www.xxxx.it/images/notizie/2016-11/terremoto_roma_evacuato_palazzo_scala_e.png" />
<!-- sh404SEF Twitter cards - end -->


I try to change photo, to upload another one more large, more small, clear cache, change setting "Automatic image detection" on "use first image in content" but the result is the same...
How can I do?
Tuesday, 22 November 2016 09:34 UTC
wb_weeblr
Hi

1 - this image, http://www.xxxx.it/images/notizie/2016-11/terremoto_roma_evacuato_palazzo_scala_e.png, does not even exist on the page. My conclusion is that it was set manually, either through the URL manager, or through another plugin

2 - I can see that you have additional OGP tags generated by another extension. Do you know what that is?

Rgds
 
Tuesday, 22 November 2016 09:48 UTC
galamarco
Hi
this image, http://www.xxxx.it/images/notizie/2016-11/terremoto_roma_evacuato_palazzo_scala_e.png, does not even exist on the page

why does not exist on the page this url?
the image url is on line 33:
<meta property="og:image" content="http://xxxx.it/images/notizie/2016-11/mappa_del_rischio_sismico_in_italia.png"/>
and line 316:
<p><img title="Mappa del rischio sismico" src="http://xxxx.it/images/notizie/2016-11/mappa_del_rischio_sismico_in_italia.png" alt="Mappa del rischio sismico" width="100%" /></p>

Conversely the image url used by component does not exist in the page...
This web site use "AL Plugin Facebook Comments for Joomla 2.5/3.0" for Facebook comment, but does not manage twitter card. For caution now I disabled the plugin
In attachment you can se the url manager and other plugin now disabled but the problem is the same.

Tuesday, 22 November 2016 09:52 UTC
wb_weeblr
Hi

this image, http://www.xxxx.it/images/notizie/2016-11/terremoto_roma_evacuato_palazzo_scala_e.png, does not even exist on the page



why does not exist on the page this url?
I am not talking about this. I am talking about the image that sh404SEF selects as the OGP/Twitter image:
<meta property="og:image" content="http://www.xxxx.it/images/notizie/2016-11/terremoto_roma_evacuato_palazzo_scala_e.png" />
<!-- sh404SEF OGP tags - end -->
<!-- sh404SEF Twitter cards -->
<meta name="twitter:image" content="http://www.xxxx.it/images/notizie/2016-11/terremoto_roma_evacuato_palazzo_scala_e.png" />


It selects an image that does not exist on the page. So this image must be set from somewhere. Either as a fallback, through another plugin or manually in the URL manager.

sh404SEF cannot "invent" an image that does not exist on the page.

This web site use "AL Plugin Facebook Comments for Joomla 2.5/3.0" for Facebook comment, but does not manage twitter card.
Right, but it looks like it does manage OGP, and so you have double OGP tags now, and they are different.

Could you please provide us with superadmin credentials to your website. You can create a temporary account, and delete it afterwards, but it must have superuser level.

Thanks and regards
 
Tuesday, 22 November 2016 10:02 UTC
galamarco
hi
I am sure that the component does not invent the url, but he uses the wrong one.
Certainly one setting is wrong, but I don't know where to find more image settings used by sh404sef.

Here your credentials:
login on http://www.xxxx.it/administrator/index.php
username: xxxx
password: xxxx
Tuesday, 22 November 2016 10:24 UTC
wb_weeblr
Hi

I am sure that the component does not invent the url, but he uses the wrong one.
It does not. This image does not exist on this page. So it has to be coming from somewhere, it cannot just appears magincally.

Spent some time testing all parts of the site, but I cannot find the full and actual reason. This seems to be linked to the "Latest news enhanced" module. When you disable it, that non-existing image is no more selected, but the article image is not selected yet, there is just no og:image or twitter:image tag at all.

Another weird thing is that if you switch back to protostar template, you get the same: this non-existing image is no longer selected, but there is no image tag at all.

There is not much more I can do online, I will have to install akeeba backup, take a backup and install a copy locally, so that I can debug directly the PHP code.

Rgds


 
Tuesday, 22 November 2016 10:42 UTC
galamarco
Hi,
here the Akeeba backup: https://xxxx

I see now on this page the component work well but I do not understand why: http://www.xxxx.it/cookie-policy.html
Tuesday, 22 November 2016 10:51 UTC
wb_weeblr
Hi

Yes, I already done the backup and downloaded.

So this issue comes from how you linked your images. You are using links such as:
src="http://xxxx.it/images/notizie/2016-11/mappa_del_rischio_sismico_in_italia.png"


In other words, you are using the wrong domain for your site (the correct domain is www.xxxx.it). Because of this, we cannot recognize that this image is local, so we cannot check its size and so we cannot use it.

Using the correct link in the article fixes the problem.

Note that currently all your images are accessible both through www and without www. ie you do not have a .htaccess redirect in place for images and other assets. You should have that, as currently you are splitting your images references between 2 separate domains, with and without www.

Rgds




 
Tuesday, 22 November 2016 10:57 UTC
galamarco
I believed that the .htaccess redirection of images and another was run by sh404sef component, I have to add it manually?
Tuesday, 22 November 2016 11:00 UTC
wb_weeblr
Hi

sh404SEF has nothing to do with URL rewriting or .htaccess. We only take care of building/decoding URLS, as an add-on inside of Joomla. URL rewriting is a server setting, and we have no effect on it.

Rgds
 
Tuesday, 22 November 2016 12:24 UTC
galamarco
thank you so much
is now active setting that sets the static url?
Tuesday, 22 November 2016 12:25 UTC
wb_weeblr
Hi

Sorry, I don't understand the question. What do you mean by static URL? which setting?

Rgds
 
Tuesday, 22 November 2016 12:51 UTC
galamarco
I apologize
I saw all the url of images and links in articles set as absolute, not relative. (With front http://www.xxxx.it/) but it is a setting in the editor.
Tuesday, 22 November 2016 13:26 UTC
wb_weeblr
Hi

Understand, yes. Links should usually not include the domain. It makes moving very hard, and in your case it's causing this issue, because the link was probably created at a time when your site was using the "naked" domain, xxxx.it instead of the current www.xxxx.it

Rgds
 
Wednesday, 07 December 2016 05:34 UTC
system
This ticket has been automatically closed. All tickets which have been inactive for a long time are automatically closed. If you believe that this ticket was closed in error, please contact us.
This ticket is closed, therefore read-only. You can no longer reply to it. If you need to provide more information, please open a new ticket and mention this ticket's number.