Here Facebook grabs the Mediawiki logo instead of the site logo.
http://www.facebook.com/groups/tg.taiwan/permalink/374509135949001/?comment_...
Doing the same experiment with e.g., http://en.wikipedia.org/wiki/1st_clan_chief , a page also without any user embedded images, oddly does not cause the mediawiki logo to be chosen.
Though it does not choose the site logo, at least it doesn't choose the mediawiki logo.
On Mon, Jun 4, 2012 at 7:35 PM, jidanni@jidanni.org wrote:
Here Facebook grabs the Mediawiki logo instead of the site logo.
http://www.facebook.com/groups/tg.taiwan/permalink/374509135949001/?comment_...
Doing the same experiment with e.g., http://en.wikipedia.org/wiki/1st_clan_chief , a page also without any user embedded images, oddly does not cause the mediawiki logo to be chosen.
Though it does not choose the site logo, at least it doesn't choose the mediawiki logo.
Didn't we discuss this almost a year ago?
Indeed, we did: http://lists.wikimedia.org/pipermail/mediawiki-l/2011-July/037710.html
-Chad
Yeah I remember that. On Jun 4, 2012 7:45 PM, "Chad" innocentkiller@gmail.com wrote:
On Mon, Jun 4, 2012 at 7:35 PM, jidanni@jidanni.org wrote:
Here Facebook grabs the Mediawiki logo instead of the site logo.
http://www.facebook.com/groups/tg.taiwan/permalink/374509135949001/?comment_...
Doing the same experiment with e.g., http://en.wikipedia.org/wiki/1st_clan_chief , a page also without any user embedded images, oddly does not cause the mediawiki logo to be chosen.
Though it does not choose the site logo, at least it doesn't choose the mediawiki logo.
Didn't we discuss this almost a year ago?
Indeed, we did: http://lists.wikimedia.org/pipermail/mediawiki-l/2011-July/037710.html
-Chad
Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
It's because the site logo is added via a background image and the only image it finds in that image next to the text "page is the powered by MediaWiki". It would show the site logi if the logo was changed to an image tag instead. Alternatively a meta tag such as <meta property="og:image" content="..path/sitelogo.png" /> could be added to the head of the document (possibly via some kind of hook) to get the desired effect.
On Tue, Jun 5, 2012 at 12:47 AM, John Du Hart compwhizii@gmail.com wrote:
Yeah I remember that. On Jun 4, 2012 7:45 PM, "Chad" innocentkiller@gmail.com wrote:
On Mon, Jun 4, 2012 at 7:35 PM, jidanni@jidanni.org wrote:
Here Facebook grabs the Mediawiki logo instead of the site logo.
http://www.facebook.com/groups/tg.taiwan/permalink/374509135949001/?comment_...
Doing the same experiment with e.g., http://en.wikipedia.org/wiki/1st_clan_chief , a page also without any user embedded images, oddly does not cause the mediawiki logo to be chosen.
Though it does not choose the site logo, at least it doesn't choose the mediawiki logo.
Didn't we discuss this almost a year ago?
Indeed, we did: http://lists.wikimedia.org/pipermail/mediawiki-l/2011-July/037710.html
-Chad
Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
OK, <meta property="og:image" content="$wgLogo" /> is what I need to add to the header of each page, as my site has no images at all except for the logo. I use the latest git version of MediaWiki.
In OutputPage.php we see function addMeta( $name, $val ) { array_push( $this->mMetatags, array( $name, $val ) ); But then http://www.mediawiki.org/wiki/Manual:Hooks/BeforePageDisplay leads to http://www.mediawiki.org/wiki/ResourceLoader/Migration_guide_for_extension_d... which makes one utterly totally lost. OK, then I found http://www.mediawiki.org/wiki/Extension:OpenGraphMeta which of course does exactly what I want... and much more. But I don't to install any extensions. All I want is to add that one little line <meta property="og:image" content="$wgLogo" /> with the $ variable (expanded like $meta["og:image"] = wfExpandUrl($wgLogo); ) or something. So how do I write the one line hook please?!
I believe this should help you: http://svn.wikimedia.org/viewvc/mediawiki/trunk/extensions/OpenGraphMeta/Ope...
Personally I'd just install the extension though.. you may find you want the other things too :)
Jon
On Tue, Jun 19, 2012 at 1:40 PM, jidanni@jidanni.org wrote:
OK, <meta property="og:image" content="$wgLogo" /> is what I need to add to the header of each page, as my site has no images at all except for the logo. I use the latest git version of MediaWiki.
In OutputPage.php we see function addMeta( $name, $val ) { array_push( $this->mMetatags, array( $name, $val ) ); But then http://www.mediawiki.org/wiki/Manual:Hooks/BeforePageDisplay leads to http://www.mediawiki.org/wiki/ResourceLoader/Migration_guide_for_extension_d... which makes one utterly totally lost. OK, then I found http://www.mediawiki.org/wiki/Extension:OpenGraphMeta which of course does exactly what I want... and much more. But I don't to install any extensions. All I want is to add that one little line
<meta property="og:image" content="$wgLogo" /> with the $ variable (expanded like $meta["og:image"] = wfExpandUrl($wgLogo); ) or something. So how do I write the one line hook please?!
OK, this extract works for 1.20 function JidanniOpenGraphMetaPageHook(&$out,&$sk){global $wgLogo; $out->addHeadItem("meta:property:og:image", Html::element('meta',array('property'=>'og:image','content'=>wfExpandUrl($wgLogo)))."\n");return true;} $wgHooks['BeforePageDisplay'][] = 'JidanniOpenGraphMetaPageHook';
wikitech-l@lists.wikimedia.org