Page MenuHomePhabricator

Support linking to the image description page of a specific "page" of an image, using wiki internal link syntax
Open, LowPublicFeature

Description

Author: snottygobble

Description:
I can display a page of a DjVu file with syntax

[[Image:Coloured Figures of English Fungi or Mushrooms.djvu|page=9|thumb]]

but if I want to create a link to that page, the obvious syntax,

[[:Image:Coloured Figures of English Fungi or Mushrooms.djvu|page=9|this]]

does not work.


Version: unspecified
Severity: enhancement

Details

Reference
bz14788

Event Timeline

bzimport raised the priority of this task from to Low.Nov 21 2014, 10:12 PM
bzimport set Reference to bz14788.

Changing component as this also applies to pdfs and any other paged media format.

For actually solving this, i'm not sure what the best choice of syntax here would be (note, I'm saying this without actually looking at the code, so this doesn't reflect how difficult any of these choices might be). [[:Image:Coloured Figures of English Fungi or Mushrooms.djvu|page=9|this]] seems a little odd, because as it stands we do not allow parameters for internal links in any case other than an image embed link. I'm not sure if we should start now. OTOH, I'm not sure what else there is - [[:Image:Coloured Figures of English Fungi or Mushrooms.djvu/9]] seems rather ugly (and then would we expect [[Image:Coloured Figures of English Fungi or Mushrooms.djvu/9]] to embed page 9. Would this have future compatability issues with some other use for image subpages [seems unlikely].)

aanet2013 wrote:

(In reply to comment #2)

Changing component as this also applies to pdfs and any other paged media
format.

For actually solving this, i'm not sure what the best choice of syntax here
would be (note, I'm saying this without actually looking at the code, so this
doesn't reflect how difficult any of these choices might be).
[[:Image:Coloured
Figures of English Fungi or Mushrooms.djvu|page=9|this]] seems a little odd,
because as it stands we do not allow parameters for internal links in any
case
other than an image embed link. I'm not sure if we should start now. OTOH,
I'm
not sure what else there is - [[:Image:Coloured Figures of English Fungi or
Mushrooms.djvu/9]] seems rather ugly (and then would we expect
[[Image:Coloured
Figures of English Fungi or Mushrooms.djvu/9]] to embed page 9. Would this
have
future compatability issues with some other use for image subpages [seems
unlikely].)

Can't we just use [[:File:filename.extension|linkname]]? In my mediawiki installation this works fine. The only problem is when you go to file page, it says there is no page linking that file, what is not true.

(In reply to comment #3)

(In reply to comment #2)

Changing component as this also applies to pdfs and any other paged media
format.

For actually solving this, i'm not sure what the best choice of syntax here
would be (note, I'm saying this without actually looking at the code, so this
doesn't reflect how difficult any of these choices might be).
[[:Image:Coloured
Figures of English Fungi or Mushrooms.djvu|page=9|this]] seems a little odd,
because as it stands we do not allow parameters for internal links in any
case
other than an image embed link. I'm not sure if we should start now. OTOH,
I'm
not sure what else there is - [[:Image:Coloured Figures of English Fungi or
Mushrooms.djvu/9]] seems rather ugly (and then would we expect
[[Image:Coloured
Figures of English Fungi or Mushrooms.djvu/9]] to embed page 9. Would this
have
future compatability issues with some other use for image subpages [seems
unlikely].)

Can't we just use [[:File:filename.extension|linkname]]? In my mediawiki
installation this works fine. The only problem is when you go to file page,
it
says there is no page linking that file, what is not true.

It would be listed at special:whatlinkshere. Only file embeddings are listed on thr filepage. However I think you miss the point. The original poster wants to link to a specific page of a file, not the file in general.

For reference, the desired *output* url is something like:

https://en.wikipedia.org/w/index.php?title=File%3AColoured_Figures_of_English_Fungi_or_Mushrooms.djvu&page=9

(Note the 'page' option on the URL). It would also makes sense that any ordinary embed like:
[[Image:Coloured Figures of English Fungi or Mushrooms.djvu|page=9|thumb]]
have the proper 'page' option in the default link.

This probably also applies to the 'lang' option and SVGs (see bug 61649, bug 58663).

I can't find how to add related links in the bug header, so here is a link to the closely related bug: T6198 (formerly bug 4198)

Hi @TrangaBallam! No updates, otherwise they would be listed here. If you or anyone is interested in contributing a software patch, please see https://www.mediawiki.org/wiki/How_to_become_a_MediaWiki_hacker - thanks!

@cscott: Hi, I'm resetting the task assignee due to inactivity. Please feel free to reclaim this task if you plan to work on this - it would be welcome! Also see https://www.mediawiki.org/wiki/Bug_management/Assignee_cleanup for more information - thanks!

Aklapper changed the subtype of this task from "Task" to "Feature Request".Feb 4 2022, 11:01 AM