How to implement the substitution of the words on the synonym?

Write website, where you can enter the word and get in response a synonym.

How to implement the mechanism?

As I see it: the server will store a text file with a list of words and appropriate synonyms for them. When you request a search for the word and retrieve the corresponding synonym.

Tell me what literature to read to implement this idea.

Perhaps there is a similar mechanism work services?
September 19th 19 at 12:35
2 answers
September 19th 19 at 12:37
1. Instead of a text file is better to use a database, what would the search was performed as quickly as possible.
2. Despite the need to use AJAX.

Not quite clear what You have a problem.
September 19th 19 at 12:39

Find more questions by tags JavaScript