guideChanging the language

The language of the CKBox UI can be changed using the language configuration option.

In the example below, CKBox is configured to use Spanish.

CKBox.mount(document.querySelector('#ckbox'), {
    tokenUrl: 'https://your.token.url',
    language: 'es'

# CKEditor integration

If you are integrating CKBox with CKEditor, please have a look at the example below, which sets the language to Spanish for both, CKEditor and CKBox simultaneously.
To read more about the integration between CKEditor and CKBox, please refer to the CKEditor integration guide.

        <meta charset="UTF-8" />
        <script src=""></script>
        <script src=""></script>
        <script src=""></script>
        <script src=""></script>
        <div id="editor"></div>
                .create( document.querySelector( '#editor' ), {
                    language: 'es',
                    ckbox: {
                        tokenUrl: 'https://your.token.url'
                    toolbar: [ 'ckbox', 'imageUpload', '|', 'heading','|', 'bold', 'italic', '|', 'undo', 'redo' ]
                } )
                .catch( error => {
                    console.error( error );
                } );

As you can see in the example above, the language option for CKBox was omitted. This was intentional because by default the language of CKBox will match the language of CKEditor, which has been already set to Spanish. Setting language again in ckbox.language would be superfluous in this case.

Below you can see a live example of the configuration presented above.