Page MenuHomePhabricator

wgWikiSeoEnableAutoDescription and TextExtracts
Closed, ResolvedPublic

Description

Dont work wgWikiSeoEnableAutoDescription with TextExtracts. If i use description2 wgWikiSeoEnableAutoDescription start work

Event Timeline

Thanks for the report. When WikiSeoEnableAutoDescription is active, after a page has been edited, WikiSEO tries to generate a description by calling TextExtracts.
With Extension:Description2 deactivated can you check any of your pages with ?action=info and report if a description prop is listed there?

I myself use WikiSeoEnableAutoDescription = true on MediaWiki 1.39 and can confirm that it is working.

Thanks for the report. When WikiSeoEnableAutoDescription is active, after a page has been edited, WikiSEO tries to generate a description by calling TextExtracts.
With Extension:Description2 deactivated can you check any of your pages with ?action=info and report if a description prop is listed there?

I myself use WikiSeoEnableAutoDescription = true on MediaWiki 1.39 and can confirm that it is working.

So I have to enter {SEO} on all pages for the description to be generated automatically?

I on Description2 and check page with ?action=info. And:

Article description: (description)
This attribute controls the content of the description and og:description elements.

Information from Extension:WikiSEO

I figured out what was causing it. On pages where templates are used (cards) that's where the description is not shown. Can I tell it to ignore templates?

I think I figured out what to do is to configure $wgExtractsRemoveClasses. I wrote this config, but nothing happens.

$wgExtractsRemoveClasses = [
"table",
"tbody",
"div",
"figure",
"script",
"input",
"style",
"ul.gallery",
"sup.reference",
"ol.references",
".error",
".nomobile",
".noprint",
".noexcerpt",
".sortkey",
".infobox",
"dl",
"h2",
"span",
"tr",
"td",
];