Page MenuHomePhabricator

Support API access to number of pages in a DjVu file
Closed, ResolvedPublic

Description

Author: snottygobble

Description:
There is no way to obtain the number of pages in a DjVu file through the API.

I suggest the best option is to provide it as part of the image info size property:

<ii size="1314181" width="1540" height="2632" pages=26/>


Version: unspecified
Severity: enhancement

Details

Reference
bz26125

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 11:21 PM
bzimport set Reference to bz26125.

snottygobble wrote:

Mediawiki deployment is now up to r77471 but imagesize still isn't returning pageCount.

See for example http://commons.wikimedia.org/w/api.php?action=query&titles=File:English%20Fairy%20Tales.djvu&prop=imageinfo&iiprop=size

Yes, because this file hasn't been synced out. That's a different branch

It's could be a while...

Bryan.TongMinh wrote:

Yeah, it may take three months or more until we sync.

Minor minor component

The api.php information component needs to be updated

Currently

  • prop=imageinfo (ii) * Returns image information and upload history

This module requires read rights
Parameters:
...
size - Adds the size of the image in bytes and the height and width

Required addition

size - Adds the size of the image in bytes and the height, width and pagecount

told to open a new request instead of reopen this. That I will do.