PHP code example of sebudesign / laravel-poeditor

1. Go to this page and download the library: Download sebudesign/laravel-poeditor 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/ */

    

sebudesign / laravel-poeditor example snippets


'providers' => [
    // ...
    SeBuDesign\PoEditor\PoEditorServiceProvider::class,
];

return [

    /*
     * The API token of POEditor can be found in your account settings in the
     * 'API Access' tab. Click on the little eye ball and copy the token. Put
     * the token in your .env file.
     */

    'api_token' => env('POEDITOR_API_TOKEN'),

    /*
     * The project id of POEditor can be found in your account settings in the
     * 'API Access' tab. Grab the project id and this package will take care of the rest.
     */

    'project_id' => env('POEDITOR_PROJECT_ID', 'YourPoEditorProjectId'),
];

$app->configure('poeditor');
$app->register(SeBuDesign\PoEditor\PoEditorServiceProvider::class);

protected function schedule(Schedule $schedule)
{
    $schedule->command('synchronise:translations')->hourly();
}
bash
php artisan vendor:publish --provider="SeBuDesign\PoEditor\PoEditorServiceProvider" --tag="config"
bash
cp vendor/sebudesign/laravel-poeditor/config/poeditor.php config/poeditor.php
bash
php artisan synchronise:translations
# With POEditor project id, replace 1234 with your project id
php artisan synchronise:translations --project=1234