1. Go to this page and download the library: Download ferdiunal/nova-translations library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
ferdiunal / nova-translations example snippets
// app/NovaServiceProvider.php
class NovaServiceProvider extends NovaApplicationServiceProvider
{
/**
* Get the tools that should be listed in the Nova sidebar.
*
* @return array
*/
public function tools()
{
return [
... // Other Nova Tools
new NovaTranslations,
];
}
}
return [
....
'services' => [
'nlpcloud' => [
// https://nlpcloud.com/
'api_key' => env('NLPCLOUD_API_KEY'),
'languages' => [
// https://docs.nlpcloud.com/#translation
// Add the language code you want here
],
],
],
];