GetTagPages does not return array of pages?

3 views
Skip to first unread message

Rob Banning

unread,
Jun 19, 2010, 6:48:20 PM6/19/10
to PBwiki API Hackers
I am trying to use the GetTagPages method to get a list of pages that
have been tagged with a particular tag. The result includes the
"pages" item in the JSON object but instead of being an array, it is
an object (really associative array) with page ID as key and page
title as value.

Is this by design and if so, why does it not return the same as
GetPages? (excuse the naive question)

Any ideas on how to use GetTagPages to get a similar result as
GetPages?

Thanks
RB

Brian Kirchoff

unread,
Jul 8, 2010, 4:24:33 PM7/8/10
to PBwiki API Hackers
Hi Rob,
Yes that is by design, we have started to change methods over to
include the object ID as the key, GetPages may eventually follow this
pattern as well.

You could use a function like PHP's array_values() in whatever
language you are using if you need the single dimensional array.

Brian
Reply all
Reply to author
Forward
0 new messages