26Jun/109

phpMyDict – Stardict web backend with PHP

Stardict is a popular open source dictionary program as well as file format for storing dictionaries. There are alternatives of StarDict, some of them better, some worse. But I never meet some WEB application to use dictionaries in StarDict format and interface through the web browser. I found this little interesting and created one...

It is written in PHP and uses MySQL as database backend, client part uses jQuery for AJAX queries. Dictionaries are indexed in admin part for quick access. By now searches through 2 mil words takes about half of the second. Interface is as simple as possible and was inspired by GoldenDict. For sample usage it contains Russian-English and English-Russian dictionary(Universal, Computer, Oil, Gas...)

Try to access it here http://a32.me/other/dict/

Comments are welcome. If I have more time and some interest to it, will release it open-source .There might be interest to use it in intranet environment.

Additional free dictionaries can be found here:

Comments (9) Trackbacks (0)
  1. I am looking for a way to create a collaborative dictionary that also allows for easy download of the online database for people to use offline. Using the Stardict format online would make the conversion way easy. Do you think it would be very hard to make it so people could submit new words and corrections that would then go to an admin to approve or delete?

    This script seems really fast and has a lot of potential – thanks!
    -Nathan

  2. Thanks )
    Depends on number of words. In case of less then 10-20K it is easier to store all words in database and write export to stardict format function. This format is really easy to handle. May be I will release PHP class to deal with it.

    Mine case is to support millions of words, it is a little bit different situation with read only dictionary access. Storing words directly into StarDict requires recreating index file each time when adding/deleting – not efficient.

  3. This is exactly what I was looking for! I already started wondering if nobody else came across this, but you apparently did :)

    I would be really interested in the php code to import the startdict data into mysql, and optionally export it again. Could you share that with us? Thnx!

  4. Does this source code also contains the code for reading the Stardict files in PHP?

  5. Thx for you awnser. Can you point me to the code? I’m trying to read the http://www.freedict.org files in php.

  6. Hi,
    I’m trying to find a php code to make own word for word translation, without Google. Do you thing your app is usable?
    Thank you, Luke

  7. And please, how can I install the source code (is it this http://a32.me/other/dict-20100821.tar.gz?)? How can I fill in the database and connect with it?
    Thank you very much…


Leave a comment

Spam protection by WP Captcha-Free

No trackbacks yet.