Page MenuHomePhabricator

Provide nocookie domain for thumb.php (generic or for Commons)
Open, Needs TriagePublicFeature

Description

Feature summary (what you would like to be able to do and where):

Ability to load a thumbnail image just by knowing the filename from a service that doesn't require any cookies.

Use case(s) (list the steps that you performed to discover that problem, and describe the actual underlying problem which you want to solve. Do not describe only a solution):

We are currently preparing for Wiki Loves Monuments in Poland. The new site is under construction at this URL: https://zabytki.toolforge.org/#!?c=51.1090:17.0328:14

Currently, we are using requests like this: https://commons.wikimedia.org/w/thumb.php?f=MaerkischerBahnhofBreslau%401902.jpg&w=200

Firefox raises concerns about cookies when using the above link (see T342624). Additionally, the traffic is heavier than necessary. It would be great if we could load the thumbnail just by knowing the filename, like "MaerkischerBahnhofBreslau%401902.jpg" from a service without cookies .

The code used at the moment:

<img
  class="card-photo"
  ng-src="https://commons.wikimedia.org/w/thumb.php?f={{$ctrl.data.image}}&w=200"
/>

We get data from a SPARQL call (if that is important).

Benefits (why should this be implemented?):

  • Less load on people's phones and network (more important while on the ground, in the wild 😉).
  • Less load on the servers (possibly related: T211661).