2011/2/13 Mohamed Mahir Ahamed Ibrahim <mahir78(a)gmail.com>om>:
Hi
I wish to have a querystring with sectionname=Name of the section. Is it
possible? or how can i acheive.
You can't do this directly, because there are all sorts of problems
with section names (duplicate names, for one thing). However, you can
retrieve the contents of a section by its number, by appending e.g.
&rvsection=3 to the normal page content query to get the content of
the 3rd section. You'd first have to look up the section number in the
section tree though.
Example:
http://en.wikipedia.org/w/api.php?action=parse&page=Barack_Obama&pr…
<s toclevel="3" level="4" line="Health care reform"
number="4.2.2"
index="15" fromtitle="Barack_Obama" byteoffset="89649"
anchor="Health_care_reform" />
So the section called "Heath care reform" (line field) has number 15
(index field).
http://en.wikipedia.org/w/api.php?action=query&prop=revisions&title…
returns the content of the section on health care reform.
Roan Kattouw (Catrope)