Keyboard Layout Converter


The «Keyboard Layout Converter» service is designed to translate text written in the English-language keyboard layout into text that corresponds to the Belarusian-language keyboard layout. The service receives the text recorded in the English-language layout as an input. After processing the text, at the output the user receives the correspondence of the input text recorded by the symbols of the Belarusian-language layout.

 

Access to the service via the API

To access the service «Keyboard Layout Converter» via the API, you should send a AJAX-request (type: POST) to the address https://corpus.by/KeyboardLayoutConverter/api.php. With an input array data the following parameters are passed:

  • text — arbitrary input text.
  • inp — keyboard layout according to which the text is printed:
    • be — Belarusian keyboard layout;
    • en — English keyboard layout;
    • ru — Russian keyboard layout.
  • outp — keyboard layout to which you want to convert the text:
    • be — Belarusian keyboard layout;
    • en — English keyboard layout;
    • ru — Russian keyboard layout.

Example of AJAX-request:

$.ajax({
   type: “POST”,
   url: “https://corpus.by/KeyboardLayoutConverter/api.php”,
   data:{
      “text”: “Ckjdf/”,
      “inp”: “en”,
      “outp”: “be”
   },
   success: function(msg){ },
   error: function() { }
});

The server returns a JSON-array with the following parameters:

  • text — input text.
  • result — resulting converted text.

For example, the following reply will be formed on the above listed AJAX-request:

[
   {
      “text”: “Ckjdf/”,
      “result”: “Слова.”
   }

]

 

If you have found a spelling error, please, notify us by selecting that text and pressing Ctrl+Enter.