Last modified: 2013-07-24 15:18:10 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T6198, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 4198 - Suggestion to implement page-level links into uploaded PDF files [[media:foo.pdf|page=n]]
Suggestion to implement page-level links into uploaded PDF files [[media:foo....
Status: NEW
Product: MediaWiki
Classification: Unclassified
Parser (Other open bugs)
1.20.x
All All
: Normal enhancement with 6 votes (vote)
: ---
Assigned To: Nobody - You can work on this!
http://www.mediawiki.org/wiki/Bugzill...
: patch, patch-reviewed
Depends on:
Blocks: Wikisource 41037
  Show dependency treegraph
 
Reported: 2005-12-06 21:06 UTC by T. Gries
Modified: 2013-07-24 15:18 UTC (History)
7 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments
Sample patch (does not quite work) (1003 bytes, patch)
2007-01-13 06:24 UTC, Brion Vibber
Details

Description T. Gries 2005-12-06 21:06:37 UTC
Preface:
One can usually create links to a certain page n (pagenumber) in PDF files by
composing links such as http://server/foo.pdf#Page=n

This also works using external links in _MediaWiki_:
* http://server/foo.pdf#Page=n (ok.)
* [http://server/foo.pdf#Page=n other text]  (ok.)

But when you want to link to a certain page in an uploaded PDF file foo.pdf

* [[media:foo.pdf#Page=n]] (not ok.) -> does _not_ work.
* [[media:foo.pdf#Page=n|other text]] (not ok.) -> does _not_ work.

I kindly ask the experts to enable the correct rendering of such links
[[media:foo.pdf#Page=n]]
Comment 1 Brion Vibber 2005-12-06 23:53:00 UTC
Can you give an example of software supporting this?
Comment 2 T. Gries 2005-12-07 02:33:51 UTC
Brion,

here you are: http://www.mediawiki.org/wiki/Bugzilla/4198 

a concise page
Comment 3 Brion Vibber 2007-01-13 06:24:58 UTC
Created attachment 3064 [details]
Sample patch (does not quite work)

It's fairly easy to stick the fragment onto the media URL as in attached patch,
but it doesn't actually work for the requested use.

Fragment identifiers on wiki links are normalized at link resolution time to
match section id headers; this turns the "=" into '.3D".

Not sure if there's a good way around that other than ripping in and redoing
how fragments are dealt with so it can be normalized differently for certain
types of output link.
Comment 4 db [inactive,noenotif] 2010-07-30 20:02:15 UTC
To show a page of a pdf, you can use [[File:PDF.pdf|page=n]], maybe it is the best, to also use page= for [[Media:PDF.pdf|page=n]] to link to a page of the pdf.
Comment 5 p858snake 2011-04-30 00:09:52 UTC
*Bulk BZ Change: +Patch to open bugs with patches attached that are missing the keyword*
Comment 6 John Mark Vandenberg 2011-09-25 02:09:23 UTC
Is the #Page=3 syntax part of any specification?  I suspect it is an feature of some PDF plugins.  It doesnt work on OSX Firefox+Preview.  It does work in Safari+Adobe plugin.

(In reply to comment #4)
> To show a page of a pdf, you can use [[File:PDF.pdf|page=n]], maybe it is the
> best, to also use page= for [[Media:PDF.pdf|page=n]] to link to a page of the
> pdf.

This has been raised as bug 14788, for djvu files but the same problem exists for any multi-page file format.
Comment 7 Bawolff (Brian Wolff) 2011-09-25 02:12:31 UTC
(In reply to comment #6)
> Is the #Page=3 syntax part of any specification?  I suspect it is an feature of
> some PDF plugins.  It doesnt work on OSX Firefox+Preview.  It does work in
> Safari+Adobe plugin.
> 
> (In reply to comment #4)
> > To show a page of a pdf, you can use [[File:PDF.pdf|page=n]], maybe it is the
> > best, to also use page= for [[Media:PDF.pdf|page=n]] to link to a page of the
> > pdf.
> 
> This has been raised as bug 14788, for djvu files but the same problem exists
> for any multi-page file format.

Mostly adobe software... http://partners.adobe.com/public/developer/en/acrobat/PDFOpenParameters.pdf#page=7

other formats (movies maybe) I think also use fragments for similar purposes (not sure)
Comment 8 T. Gries 2011-09-25 07:08:17 UTC
(In reply to comment #4)
> To show a page of a pdf, you can use [[File:PDF.pdf|page=n]], maybe it is the
> best, to also use page= for [[Media:PDF.pdf|page=n]] to link to a page of the
> pdf.

Was that meant as a suggestion for implementation, or what else? It does not work for me.
Comment 9 db [inactive,noenotif] 2011-09-25 08:23:10 UTC
(In reply to comment #8)
> (In reply to comment #4)
> > To show a page of a pdf, you can use [[File:PDF.pdf|page=n]], maybe it is the
> > best, to also use page= for [[Media:PDF.pdf|page=n]] to link to a page of the
> > pdf.
> Was that meant as a suggestion for implementation, or what else? It does not
> work for me.

[[File:PDF.pdf|page=n]] should work at the moment to include a page of a multi page file into the wikipage

[[Media:PDF.pdf|page=n]] is a suggestion for implementation for a link to the page of the multi page file, with the #page= anchor.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links