Hello Friends at Media Wiki,
We have a web site using MediaWiki code 1.19.1 where one can look up words.
We have entered test words in Sanskrit to the database. A few use the
letter 'c' as a first letter ( for lookup purposes) then the Sanskrit
letters of a word follow. Some are only Sankrit letters. When i query the
database for words starting with 'c' it gives me the records and displays
the si_title field which includes the test words with Sanskrit characters
that start with the letter 'c' and the rest of the letters are Sanskrit.
The query is as follows:
$result = mysql_query(
"SELECT si_page, si_title FROM saa_searchindex WHERE left(si_title,1) =
'" . $_GET['letter'] . "' order by si_title ");
I put a Sanskrit letter on the page ( code shown below) as a link to run
the same query as above and it picks up and displays all words starting
with that Sanskrit letter.
printf('<a href="http://192.168.0.248:8087/skins/AlphaSearch.php?letter='
.
"\xE0\xA4\x85" .'" class="myclass">%1$s</a> ',
"\xE0\xA4\x85");
When i do either of these queries all the words found are put in a table
on the web page as links.
while ( $row = mysql_fetch_array($result) ) {
$word = $row["si_title"];
$page = $row["si_page"];
printf('<td><a href="http://192.168.0.248:8087/index.php?search=' .
$word .
' " &go=GO HTTP/1.1">%s</a></td> ', $word);}
Then by clicking on the link that word is looked up and displayed. In
English this works fine. For Sanskrit words the link displays all in
Sanskrit characters but when clicking on the link it never can find the
Sanskrit word in the database. So the Sanskrit Character i put on the page
as a link was put in by utf8 char code. When a user types in a Sanskrit
letter or word or when the Sanskrit word is displayed as above it can't be
found by the media wiki query.
Any ideas on how to solve this.
And can anyone tell me where the actual code line of the sql query
(index.php?search=) is in the media wiki code files?
Thank you so much for your help, Markandeya