Page MenuHomePhabricator

Change TItle from "{Label} {ZID} {Type} - Wikifunctions" to just "{Label} - WIkifunctions"
Closed, ResolvedPublic

Assigned To
Authored By
DVrandecic
Mar 15 2024, 12:02 AM
Referenced Files
F55232711: CleanShot 2024-06-11 at 14.25.58@2x.png
Jun 11 2024, 12:27 PM
F55232692: image.png
Jun 11 2024, 12:27 PM
F42643168: image.png
Mar 15 2024, 11:52 AM
F42642909: image.png
Mar 15 2024, 11:52 AM
F42642886: image.png
Mar 15 2024, 11:52 AM
F42642793: image.png
Mar 15 2024, 11:52 AM
F42642756: image.png
Mar 15 2024, 11:52 AM

Description

Go to https://www.wikifunctions.org/view/en/Z10000

The title of the page (e.g. displayed in the browser tab) is

"join strings Z10000 Function - Wikifunctions"

We can drop the ZID from the title, and maybe even the type (i.e. "Function" in the example), so it is only

"join strings - Wikifunctions"

Event Timeline

I think we can drop the ZID from the title, and maybe even the type (i.e. "Function" in the example), so it is only

"join strings - Wikifunctions"

+1! i was running queries on search engines (google, duckduckgo, ...) and i think we could keep "join strings - Wikifunctions" or even just the title. why? because in the browser it's usually displayed next to the favicon (eg. firefox)

image.png (902×190 px, 26 KB)

or with the URL, which includes the word "wikifunctions" (eg. chrome)

image.png (1,020×372 px, 91 KB)

while thinking about this, i also noticed that we could include the object description as meta description, this is how it currently looks on DDG

image.png (1,344×242 px, 64 KB)

if we make the suggested changes it would look like this w/o "- Wikifunctions"

image.png (868×184 px, 32 KB)

or with

image.png (868×202 px, 37 KB)

DVrandecic triaged this task as Lowest priority.Mar 21 2024, 4:44 PM

It seems MediaWiki makes this a bit difficult? Would be great to happen but let's not spend a lot of resources on this.

I love all suggestions.

The reason why I lean a bit towards "Join empty strings - Wikifunctions" is to keep it consistent with the other Wikimedia properties (i.e. Wikipedia has "Milan - Wikipedia", Wikidata has "San Francisco - Wikidata", etc.) -- but happy to even go one step further :) Leaving the decision with you, @AAlhazwani-WMF (and once you made it, untag yourself and design and it can be picked up by engineering)

AAlhazwani-WMF removed a project: Design.

I love all suggestions.

The reason why I lean a bit towards "Join empty strings - Wikifunctions" is to keep it consistent with the other Wikimedia properties (i.e. Wikipedia has "Milan - Wikipedia", Wikidata has "San Francisco - Wikidata", etc.) -- but happy to even go one step further :) Leaving the decision with you, @AAlhazwani-WMF (and once you made it, untag yourself and design and it can be picked up by engineering)

agreed! let's use the same approach then "object name" + "-" + "project name" as the other wiki projects.

I [do not] object to this change [see below]

There may just be a missing dependency on some other task, but I always use the ZID in the title to create links on-wiki. I don’t want to have to extract it from the url every time.

The ability to copy the function’s ZID by clicking on it is convenient on the Implementation page, and a similar option should be available on all pages before the ZID is removed from the title.

Please see: T360001#9626082.

@AAlhazwani-WMF, @DVrandecic

I object to this change.

There may just be a missing dependency on some other task, but I always use the ZID in the title to create links on-wiki. I don’t want to have to extract it from the url every time.

The ability to copy the function’s ZID by clicking on it is convenient on the Implementation page, and a similar option should be available on all pages before the ZID is removed from the title.

Please see: T360001#9626082.

@AAlhazwani-WMF, @DVrandecic

@GrounderUK which title are you referring to? this proposal is to change the metadata <title> in the HTML. we're not touching the content of the mediawiki header that is going to stay as is.

this is the current

image.png (2,684×354 px, 179 KB)

and this is the proposed change

CleanShot 2024-06-11 at 14.25.58@2x.png (2,560×360 px, 163 KB)

Ah, okay… thanks. It looks like T367139 was merged/closed in error?

Ah, okay… thanks. It looks like T367139 was merged/closed in error?

thank you, i just wanted to be extra sure :) reading through T367139 description, i do think that task is a duplicate of this one.

Ah, okay… thanks. It looks like T367139 was merged/closed in error?

thank you, i just wanted to be extra sure :) reading through T367139 description, i do think that task is a duplicate of this one.

Yes, I just reached the same conclusion. I have no objections to changing the text marked up with <title>. Sorry for the confusion and thank you for the clarification.

But how about the title for the edit page and so? There its for example : Edit Implementation: {title} Z10002 - MediaWiki/Wikifunctions.

Should that be changed aswell?

If easy. yes, change that as well in this task. If not, feel free to make a new ticket for that.

So I made a WIP Gerrit Patch.

For the SpecialViewObject.php it seems very easy and there is a mw method to setHTMLTitle on the $outputPage.

Put the ZObjectContentHandler.php sets the h1 and title with setTitleText()
If you try to set the setHTMLTitle underneath by getting the$ output, that does nothing. setTitleText takes precedence over the setHTMLTitle.

$output = RequestContext::getMain()->getOutput();
$output->setHTMLTitle( 'some title' );

I haven't found a straightforward method to set just the HTML title there yet.
Perhaps someone else would like to tackle the TODO in the patch?

When an Object is untitled, should we set the <title> metadata to "Untitled - Wikifunctions" or "Zid - Wikifunctions"?

cc @DVrandecic @AAlhazwani-WMF

When an Object is untitled, should we set the <title> metadata to "Untitled - Wikifunctions" or "Zid - Wikifunctions"?

cc @DVrandecic @AAlhazwani-WMF

for the meta title i'd say zid.

Change #1052137 had a related patch set uploaded (by Genoveva Galarza; author: Daphne Smit):

[mediawiki/extensions/WikiLambda@master] Change title meta tag from "{Label} {ZID} {Type} - Wikifunctions" to just "{Label} - WIkifunctions"

https://gerrit.wikimedia.org/r/1052137

Change #1052137 merged by jenkins-bot:

[mediawiki/extensions/WikiLambda@master] Change title meta tag from "{Label} {ZID} {Type} - Wikifunctions" to just "{Label} - WIkifunctions"

https://gerrit.wikimedia.org/r/1052137