5

I am attempting to add case-insensitivity to my Wikipedia api calls. Wikipedia is case-sensitive in how it names pages. So, http://en.wikipedia.org/wiki/Cat will yield a page about the animal, http://en.wikipedia.org/wiki/CAT will yield a disambiguation page, and http://en.wikipedia.org/wiki/CAt will yield a notification that the page doesn't exist.

My current problem is that I would like to use the API to return pages the same way Wikipedia does. I am currently using the following API call in Python:

"http://en.wikipedia.org/w/index.php?title=" + topic + "&action=render"

When searching on Wikipedia using the GUI's search box, "cat" and "CAt" will return the page about the animal, while "cAT" and "CAT" will return the disambiguation page.

How can I replicate this behavior through the API?

Damjan Pavlica
  • 31,277
  • 10
  • 71
  • 76
cryptic_star
  • 1,863
  • 3
  • 26
  • 47

1 Answers1

3

Case insensitive search is done through the Opensearch API.

Tgr
  • 27,442
  • 12
  • 81
  • 118